=== Test case: rest_client_SUITE:add_contact_and_invite/1 (click for source code)
=== Config value:
[{watchdog,<0.87799.0>},
{muc_light_host,<<"muclight.localhost">>},
{mam_backend,rdbms},
{preset,"mysql_redis"},
{mim_data_dir,"/home/circleci/project/big_tests/tests/rest_client_SUITE_data"},
{tc_logfile,"/home/circleci/project/big_tests/ct_report/ct_run.test@1fbe638fdeaa.2024-02-15_09.57.53/big_tests.tests.rest_client_SUITE.logs/run.2024-02-15_10.13.17/rest_client_suite.add_contact_and_invite.106628.html"},
{tc_group_properties,[{name,roster},parallel]},
{tc_group_path,[]},
{data_dir,"/home/circleci/project/big_tests/_build/default/lib/mongoose_tests/ebin/rest_client_SUITE_data/"},
{priv_dir,"/home/circleci/project/big_tests/ct_report/ct_run.test@1fbe638fdeaa.2024-02-15_09.57.53/big_tests.tests.rest_client_SUITE.logs/run.2024-02-15_10.13.17/log_private/"},
{{saved_modules,mongooseim@localhost,<<"localhost">>},
#{mod_vcard =>
#{matches => 30,
host => {prefix,<<"vjud.">>},
search => true,backend => rdbms,iqdisc => parallel},
mod_roster =>
#{backend => rdbms,iqdisc => one_queue,versioning => false,
store_current_id => false},
mod_register =>
#{access => register,iqdisc => one_queue,
registration_watchers => [],password_strength => 0,
ip_access => [{allow,"127.0.0.0/8"},{deny,"0.0.0.0/0"}]},
mod_sic => #{iqdisc => one_queue},
mod_amp => #{},mod_presence => #{},
mod_disco =>
#{iqdisc => one_queue,server_info => [],extra_domains => [],
users_can_see_hidden_services => false},
mod_stream_management =>
#{buffer => true,ack => true,backend => mnesia,
stale_h =>
#{enabled => false,repeat_after => 1800,geriatric => 3600},
buffer_max => 100,ack_freq => 1,resume_timeout => 600},
mod_adhoc => #{iqdisc => one_queue,report_commands_node => false},
mod_bosh =>
#{backend => mnesia,inactivity => 30,max_pause => 120,
max_wait => infinity,server_acks => false},
mod_cache_users =>
#{strategy => fifo,number_of_segments => 5,time_to_live => 2},
mod_carboncopy => #{iqdisc => no_queue}}}]
=== Current directory is "/home/circleci/project/big_tests/ct_report/ct_run.test@1fbe638fdeaa.2024-02-15_09.57.53"
=== Started at 2024-02-15 10:13:19
*** User 2024-02-15 10:13:19.461 ***🔗
alicE_add_contact_and_invite_3134@localhost/res1 out
<stream:stream to='localhost' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>
*** User 2024-02-15 10:13:19.462 ***🔗
alicE_add_contact_and_invite_3134@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='b9b2c2e9a702aa04' from='localhost' version='1.0' xml:lang='en'>
*** User 2024-02-15 10:13:19.462 ***🔗
alicE_add_contact_and_invite_3134@localhost/res1 in
<stream:features>
<register xmlns='http://jabber.org/features/iq-register'/>
<starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>
<mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
<mechanism>SCRAM-SHA-256</mechanism>
<mechanism>PLAIN</mechanism>
</mechanisms>
<amp xmlns='http://jabber.org/feature/amp'/>
<sm xmlns='urn:xmpp:sm:3'/>
</stream:features>
*** User 2024-02-15 10:13:19.462 ***🔗
alicE_add_contact_and_invite_3134@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGFsaWNFX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzEzNABtYXR5Z3J5c2E=</auth>
*** User 2024-02-15 10:13:19.462 ***🔗
alicE_add_contact_and_invite_3134@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
*** User 2024-02-15 10:13:19.463 ***🔗
alicE_add_contact_and_invite_3134@localhost/res1 out
<stream:stream to='localhost' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>
*** User 2024-02-15 10:13:19.463 ***🔗
alicE_add_contact_and_invite_3134@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='d364d78b7ecd7a30' from='localhost' version='1.0' xml:lang='en' to='alice_add_contact_and_invite_3134@localhost'>
*** User 2024-02-15 10:13:19.463 ***🔗
alicE_add_contact_and_invite_3134@localhost/res1 in
<stream:features>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'/>
<register xmlns='http://jabber.org/features/iq-register'/>
<amp xmlns='http://jabber.org/feature/amp'/>
<sm xmlns='urn:xmpp:sm:3'/>
</stream:features>
*** User 2024-02-15 10:13:19.463 ***🔗
alicE_add_contact_and_invite_3134@localhost/res1 out
<iq type='set' id='4b180cbfe38d3220012e71f05943098b'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<resource>res1</resource>
</bind>
</iq>
*** User 2024-02-15 10:13:19.463 ***🔗
alicE_add_contact_and_invite_3134@localhost/res1 in
<iq id='4b180cbfe38d3220012e71f05943098b' type='result'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<jid>alice_add_contact_and_invite_3134@localhost/res1</jid>
</bind>
</iq>
*** User 2024-02-15 10:13:19.463 ***🔗
alice_add_contact_and_invite_3134@localhost/res1 out
<iq type='set' id='ca7727a4d4cea6eb4a747fd336a8bddc'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-02-15 10:13:19.464 ***🔗
alice_add_contact_and_invite_3134@localhost/res1 in
<iq from='localhost' to='alice_add_contact_and_invite_3134@localhost/res1' id='ca7727a4d4cea6eb4a747fd336a8bddc' type='result'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-02-15 10:13:19.464 ***🔗
alice_add_contact_and_invite_3134@localhost/res1 out
<presence/>
*** User 2024-02-15 10:13:19.465 ***🔗
alice_add_contact_and_invite_3134@localhost/res1 in
<presence from='alice_add_contact_and_invite_3134@localhost/res1' to='alice_add_contact_and_invite_3134@localhost/res1'/>
*** User 2024-02-15 10:13:19.466 ***🔗
bOb_add_contact_and_invite_3134@localhost/res1 out
<stream:stream to='localhost' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>
*** User 2024-02-15 10:13:19.466 ***🔗
bOb_add_contact_and_invite_3134@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='f5c7fc941fdbcf14' from='localhost' version='1.0' xml:lang='en'>
*** User 2024-02-15 10:13:19.466 ***🔗
bOb_add_contact_and_invite_3134@localhost/res1 in
<stream:features>
<register xmlns='http://jabber.org/features/iq-register'/>
<starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>
<mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
<mechanism>SCRAM-SHA-256</mechanism>
<mechanism>PLAIN</mechanism>
</mechanisms>
<amp xmlns='http://jabber.org/feature/amp'/>
<sm xmlns='urn:xmpp:sm:3'/>
</stream:features>
*** User 2024-02-15 10:13:19.466 ***🔗
bOb_add_contact_and_invite_3134@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGJPYl9hZGRfY29udGFjdF9hbmRfaW52aXRlXzMxMzQAbWFrcm9saWth</auth>
*** User 2024-02-15 10:13:19.470 ***🔗
bOb_add_contact_and_invite_3134@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
*** User 2024-02-15 10:13:19.470 ***🔗
bOb_add_contact_and_invite_3134@localhost/res1 out
<stream:stream to='localhost' version='1.0' xml:lang='en' xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams'>
*** User 2024-02-15 10:13:19.470 ***🔗
bOb_add_contact_and_invite_3134@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='ebe9ea69376432ea' from='localhost' version='1.0' xml:lang='en' to='bob_add_contact_and_invite_3134@localhost'>
*** User 2024-02-15 10:13:19.471 ***🔗
bOb_add_contact_and_invite_3134@localhost/res1 in
<stream:features>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'/>
<register xmlns='http://jabber.org/features/iq-register'/>
<amp xmlns='http://jabber.org/feature/amp'/>
<sm xmlns='urn:xmpp:sm:3'/>
</stream:features>
*** User 2024-02-15 10:13:19.471 ***🔗
bOb_add_contact_and_invite_3134@localhost/res1 out
<iq type='set' id='fee9e78043b07521e44c4b0d145d146b'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<resource>res1</resource>
</bind>
</iq>
*** User 2024-02-15 10:13:19.471 ***🔗
bOb_add_contact_and_invite_3134@localhost/res1 in
<iq id='fee9e78043b07521e44c4b0d145d146b' type='result'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<jid>bob_add_contact_and_invite_3134@localhost/res1</jid>
</bind>
</iq>
*** User 2024-02-15 10:13:19.471 ***🔗
bob_add_contact_and_invite_3134@localhost/res1 out
<iq type='set' id='f1bb480ca0ec7bf8c19d02755788aa04'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-02-15 10:13:19.471 ***🔗
bob_add_contact_and_invite_3134@localhost/res1 in
<iq from='localhost' to='bob_add_contact_and_invite_3134@localhost/res1' id='f1bb480ca0ec7bf8c19d02755788aa04' type='result'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-02-15 10:13:19.471 ***🔗
bob_add_contact_and_invite_3134@localhost/res1 out
<presence/>
*** User 2024-02-15 10:13:19.474 ***🔗
bob_add_contact_and_invite_3134@localhost/res1 in
<presence from='bob_add_contact_and_invite_3134@localhost/res1' to='bob_add_contact_and_invite_3134@localhost/res1'/>
*** User 2024-02-15 10:13:19.495 ***🔗
REST request:
Code: 200
Req: {<0.87868.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"36ab5d73495c4e2f">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzEzNEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 15 Feb 2024 10:13:19 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"2">>}],
<<"[]">>,125,8165}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
body => <<>>,method => <<"GET">>,
creds =>
{<<"bob_add_contact_and_invite_3134@localhost">>,
<<"makrolika">>},
role => client,return_headers => true}
*** User 2024-02-15 10:13:19.511 ***🔗
REST request:
Code: 204
Req: {<0.87891.0>,<<"/api/contacts">>,<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"e74c97dfb7252064">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzEzNEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<"{\"jid\":\"alice_add_contact_and_invite_3134@localhost\"}">>}
Result: {{<<"204">>,<<"No Content">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 15 Feb 2024 10:13:19 GMT">>}],
<<>>,80,6294}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
body =>
<<"{\"jid\":\"alice_add_contact_and_invite_3134@localhost\"}">>,
method => <<"POST">>,
creds =>
{<<"bob_add_contact_and_invite_3134@localhost">>,
<<"makrolika">>},
role => client,return_headers => true}
*** User 2024-02-15 10:13:19.511 ***🔗
bob_add_contact_and_invite_3134@localhost/res1 in
<iq from='bob_add_contact_and_invite_3134@localhost' to='bob_add_contact_and_invite_3134@localhost/res1' id='pusha9543531773271ec' type='set'>
<query xmlns='jabber:iq:roster'>
<item subscription='none' jid='alice_add_contact_and_invite_3134@localhost'/>
</query>
</iq>
*** User 2024-02-15 10:13:19.531 ***🔗
REST request:
Code: 200
Req: {<0.87918.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"98a86a7335692408">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzEzNEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 15 Feb 2024 10:13:19 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"90">>}],
<<"[{\"ask\":\"none\",\"subscription\":\"none\",\"jid\":\"alice_add_contact_and_invite_3134@localhost\"}]">>,
214,10400}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
body => <<>>,method => <<"GET">>,
creds =>
{<<"bob_add_contact_and_invite_3134@localhost">>,
<<"makrolika">>},
role => client,return_headers => true}
*** User 2024-02-15 10:13:19.592 ***🔗
REST request:
Code: 204
Req: {<0.87954.0>,
<<"/api/contacts/alice_add_contact_and_invite_3134@localhost">>,
<<"PUT">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"b8512027bbbb3288">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzEzNEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<"{\"action\":\"invite\"}">>}
Result: {{<<"204">>,<<"No Content">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 15 Feb 2024 10:13:19 GMT">>}],
<<>>,80,53773}
Params: #{path =>
<<"/api/contacts/alice_add_contact_and_invite_3134@localhost">>,
server => #{node => mongooseim@localhost},
body => <<"{\"action\":\"invite\"}">>,method => <<"PUT">>,
creds =>
{<<"bob_add_contact_and_invite_3134@localhost">>,
<<"makrolika">>},
role => client,return_headers => true}
*** User 2024-02-15 10:13:19.592 ***🔗
bob_add_contact_and_invite_3134@localhost/res1 in
<iq from='bob_add_contact_and_invite_3134@localhost' to='bob_add_contact_and_invite_3134@localhost/res1' id='pushef9b1bc71cfe3295' type='set'>
<query xmlns='jabber:iq:roster'>
<item ask='subscribe' subscription='none' jid='alice_add_contact_and_invite_3134@localhost'/>
</query>
</iq>
*** User 2024-02-15 10:13:19.592 ***🔗
Push2: {xmlel,<<"iq">>,
[{<<"from">>,<<"bob_add_contact_and_invite_3134@localhost">>},
{<<"to">>,<<"bob_add_contact_and_invite_3134@localhost/res1">>},
{<<"id">>,<<"pushef9b1bc71cfe3295">>},
{<<"type">>,<<"set">>}],
[{xmlel,<<"query">>,
[{<<"xmlns">>,<<"jabber:iq:roster">>}],
[{xmlel,<<"item">>,
[{<<"ask">>,<<"subscribe">>},
{<<"subscription">>,<<"none">>},
{<<"jid">>,
<<"alice_add_contact_and_invite_3134@localhost">>}],
[]}]}]}
*** User 2024-02-15 10:13:19.592 ***🔗
alice_add_contact_and_invite_3134@localhost/res1 in
<presence from='bob_add_contact_and_invite_3134@localhost' to='alice_add_contact_and_invite_3134@localhost/res1' type='subscribe'/>
*** User 2024-02-15 10:13:19.615 ***🔗
REST request:
Code: 200
Req: {<0.87995.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"9e5a6fe8b6d0b95c">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzEzNEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 15 Feb 2024 10:13:19 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"89">>}],
<<"[{\"ask\":\"out\",\"subscription\":\"none\",\"jid\":\"alice_add_contact_and_invite_3134@localhost\"}]">>,
213,11640}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
body => <<>>,method => <<"GET">>,
creds =>
{<<"bob_add_contact_and_invite_3134@localhost">>,
<<"makrolika">>},
role => client,return_headers => true}
*** User 2024-02-15 10:13:19.615 ***🔗
alice_add_contact_and_invite_3134@localhost/res1 out
<iq type='set' id='708431393a510eaaebc17273f1604b3f'>
<query xmlns='jabber:iq:roster'>
<item jid='bob_add_contact_and_invite_3134@localhost' name='Bob'/>
</query>
</iq>
*** User 2024-02-15 10:13:19.619 ***🔗
alice_add_contact_and_invite_3134@localhost/res1 in
<iq from='alice_add_contact_and_invite_3134@localhost' to='alice_add_contact_and_invite_3134@localhost/res1' id='push42d0b1fe11c60417' type='set'>
<query xmlns='jabber:iq:roster'>
<item subscription='none' name='Bob' jid='bob_add_contact_and_invite_3134@localhost'/>
</query>
</iq>
*** User 2024-02-15 10:13:19.620 ***🔗
alice_add_contact_and_invite_3134@localhost/res1 out
<iq to='alice_add_contact_and_invite_3134@localhost' id='push42d0b1fe11c60417' type='result'/>
*** User 2024-02-15 10:13:19.620 ***🔗
alice_add_contact_and_invite_3134@localhost/res1 in
<iq from='alice_add_contact_and_invite_3134@localhost' to='alice_add_contact_and_invite_3134@localhost/res1' id='708431393a510eaaebc17273f1604b3f' type='result'/>
*** User 2024-02-15 10:13:19.620 ***🔗
alice_add_contact_and_invite_3134@localhost/res1 out
<presence type='subscribed' to='bob_add_contact_and_invite_3134@localhost'/>
*** User 2024-02-15 10:13:19.631 ***🔗
bob_add_contact_and_invite_3134@localhost/res1 in
<iq from='bob_add_contact_and_invite_3134@localhost' to='bob_add_contact_and_invite_3134@localhost/res1' id='pushfa69786989c8ba53' type='set'>
<query xmlns='jabber:iq:roster'>
<item subscription='to' jid='alice_add_contact_and_invite_3134@localhost'/>
</query>
</iq>
*** User 2024-02-15 10:13:19.631 ***🔗
Push3 {xmlel,<<"iq">>,
[{<<"from">>,<<"bob_add_contact_and_invite_3134@localhost">>},
{<<"to">>,<<"bob_add_contact_and_invite_3134@localhost/res1">>},
{<<"id">>,<<"pushfa69786989c8ba53">>},
{<<"type">>,<<"set">>}],
[{xmlel,<<"query">>,
[{<<"xmlns">>,<<"jabber:iq:roster">>}],
[{xmlel,<<"item">>,
[{<<"subscription">>,<<"to">>},
{<<"jid">>,
<<"alice_add_contact_and_invite_3134@localhost">>}],
[]}]}]}
*** User 2024-02-15 10:13:19.649 ***🔗
REST request:
Code: 200
Req: {<0.88056.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"7e701b4e5cabdb0a">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzEzNEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 15 Feb 2024 10:13:19 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"88">>}],
<<"[{\"ask\":\"none\",\"subscription\":\"to\",\"jid\":\"alice_add_contact_and_invite_3134@localhost\"}]">>,
212,6152}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
body => <<>>,method => <<"GET">>,
creds =>
{<<"bob_add_contact_and_invite_3134@localhost">>,
<<"makrolika">>},
role => client,return_headers => true}
*** User 2024-02-15 10:13:19.649 ***🔗
bob_add_contact_and_invite_3134@localhost/res1 out
</stream:stream>
*** User 2024-02-15 10:13:19.650 ***🔗
bob_add_contact_and_invite_3134@localhost/res1 in
</stream:stream>
*** User 2024-02-15 10:13:19.650 ***🔗
alice_add_contact_and_invite_3134@localhost/res1 out
</stream:stream>
*** User 2024-02-15 10:13:19.650 ***🔗
alice_add_contact_and_invite_3134@localhost/res1 in
</stream:stream>
=== Ended at 2024-02-15 10:13:19
=== successfully completed test case
=== === Returned value: ok