=== Test case: rest_client_SUITE:add_contact_and_invite/1 (click for source code)
=== Config value:
[{watchdog,<0.80104.0>},
{muc_light_host,<<"muclight.localhost">>},
{mam_backend,rdbms},
{preset,"pgsql_cets"},
{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@fe524ba9ae35.2024-03-11_09.05.30/big_tests.tests.rest_client_SUITE.logs/run.2024-03-11_09.20.06/rest_client_suite.add_contact_and_invite.113540.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@fe524ba9ae35.2024-03-11_09.05.30/big_tests.tests.rest_client_SUITE.logs/run.2024-03-11_09.20.06/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_amp => #{},
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_disco =>
#{iqdisc => one_queue,server_info => [],extra_domains => [],
users_can_see_hidden_services => false},
mod_presence => #{},
mod_stream_management =>
#{buffer => true,ack => true,backend => cets,
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 => cets,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@fe524ba9ae35.2024-03-11_09.05.30"
=== Started at 2024-03-11 09:20:10
*** User 2024-03-11 09:20:10.792 ***🔗
alicE_add_contact_and_invite_2904@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-03-11 09:20:10.793 ***🔗
alicE_add_contact_and_invite_2904@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='9555f5743715496c' from='localhost' version='1.0' xml:lang='en'>
*** User 2024-03-11 09:20:10.793 ***🔗
alicE_add_contact_and_invite_2904@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-03-11 09:20:10.793 ***🔗
alicE_add_contact_and_invite_2904@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGFsaWNFX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjkwNABtYXR5Z3J5c2E=</auth>
*** User 2024-03-11 09:20:10.796 ***🔗
alicE_add_contact_and_invite_2904@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
*** User 2024-03-11 09:20:10.796 ***🔗
alicE_add_contact_and_invite_2904@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-03-11 09:20:10.796 ***🔗
alicE_add_contact_and_invite_2904@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='8fe1c403639fbcfa' from='localhost' version='1.0' xml:lang='en' to='alice_add_contact_and_invite_2904@localhost'>
*** User 2024-03-11 09:20:10.796 ***🔗
alicE_add_contact_and_invite_2904@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-03-11 09:20:10.797 ***🔗
alicE_add_contact_and_invite_2904@localhost/res1 out
<iq type='set' id='813bb622909d2ee30c19e2c5e953569c'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<resource>res1</resource>
</bind>
</iq>
*** User 2024-03-11 09:20:10.797 ***🔗
alicE_add_contact_and_invite_2904@localhost/res1 in
<iq id='813bb622909d2ee30c19e2c5e953569c' type='result'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<jid>alice_add_contact_and_invite_2904@localhost/res1</jid>
</bind>
</iq>
*** User 2024-03-11 09:20:10.797 ***🔗
alice_add_contact_and_invite_2904@localhost/res1 out
<iq type='set' id='77aeba25e53e609eddd8cb2854471dfc'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-03-11 09:20:10.800 ***🔗
alice_add_contact_and_invite_2904@localhost/res1 in
<iq from='localhost' to='alice_add_contact_and_invite_2904@localhost/res1' id='77aeba25e53e609eddd8cb2854471dfc' type='result'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-03-11 09:20:10.800 ***🔗
alice_add_contact_and_invite_2904@localhost/res1 out
<presence/>
*** User 2024-03-11 09:20:10.816 ***🔗
alice_add_contact_and_invite_2904@localhost/res1 in
<presence from='alice_add_contact_and_invite_2904@localhost/res1' to='alice_add_contact_and_invite_2904@localhost/res1'/>
*** User 2024-03-11 09:20:10.819 ***🔗
bOb_add_contact_and_invite_2904@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-03-11 09:20:10.821 ***🔗
bOb_add_contact_and_invite_2904@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='d65b5d55f3abcd2e' from='localhost' version='1.0' xml:lang='en'>
*** User 2024-03-11 09:20:10.821 ***🔗
bOb_add_contact_and_invite_2904@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-03-11 09:20:10.821 ***🔗
bOb_add_contact_and_invite_2904@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGJPYl9hZGRfY29udGFjdF9hbmRfaW52aXRlXzI5MDQAbWFrcm9saWth</auth>
*** User 2024-03-11 09:20:10.824 ***🔗
bOb_add_contact_and_invite_2904@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
*** User 2024-03-11 09:20:10.824 ***🔗
bOb_add_contact_and_invite_2904@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-03-11 09:20:10.824 ***🔗
bOb_add_contact_and_invite_2904@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='1b9590c96d8a22d7' from='localhost' version='1.0' xml:lang='en' to='bob_add_contact_and_invite_2904@localhost'>
*** User 2024-03-11 09:20:10.824 ***🔗
bOb_add_contact_and_invite_2904@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-03-11 09:20:10.824 ***🔗
bOb_add_contact_and_invite_2904@localhost/res1 out
<iq type='set' id='554ae6cd76993d9699b50fad2875443d'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<resource>res1</resource>
</bind>
</iq>
*** User 2024-03-11 09:20:10.824 ***🔗
bOb_add_contact_and_invite_2904@localhost/res1 in
<iq id='554ae6cd76993d9699b50fad2875443d' type='result'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<jid>bob_add_contact_and_invite_2904@localhost/res1</jid>
</bind>
</iq>
*** User 2024-03-11 09:20:10.825 ***🔗
bob_add_contact_and_invite_2904@localhost/res1 out
<iq type='set' id='f6d2a7b0230e75b41bc4be423db75590'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-03-11 09:20:10.830 ***🔗
bob_add_contact_and_invite_2904@localhost/res1 in
<iq from='localhost' to='bob_add_contact_and_invite_2904@localhost/res1' id='f6d2a7b0230e75b41bc4be423db75590' type='result'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-03-11 09:20:10.830 ***🔗
bob_add_contact_and_invite_2904@localhost/res1 out
<presence/>
*** User 2024-03-11 09:20:10.834 ***🔗
bob_add_contact_and_invite_2904@localhost/res1 in
<presence from='bob_add_contact_and_invite_2904@localhost/res1' to='bob_add_contact_and_invite_2904@localhost/res1'/>
*** User 2024-03-11 09:20:10.879 ***🔗
REST request:
Code: 200
Req: {<0.80180.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"067ff2d6a839bb59">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjkwNEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Mon, 11 Mar 2024 09:20:10 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"2">>}],
<<"[]">>,125,30529}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
method => <<"GET">>,
creds =>
{<<"bob_add_contact_and_invite_2904@localhost">>,
<<"makrolika">>},
body => <<>>,role => client,return_headers => true}
*** User 2024-03-11 09:20:10.933 ***🔗
REST request:
Code: 204
Req: {<0.80215.0>,<<"/api/contacts">>,<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"57e8a400bbae5871">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjkwNEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<"{\"jid\":\"alice_add_contact_and_invite_2904@localhost\"}">>}
Result: {{<<"204">>,<<"No Content">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Mon, 11 Mar 2024 09:20:10 GMT">>}],
<<>>,80,37479}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
method => <<"POST">>,
creds =>
{<<"bob_add_contact_and_invite_2904@localhost">>,
<<"makrolika">>},
body =>
<<"{\"jid\":\"alice_add_contact_and_invite_2904@localhost\"}">>,
role => client,return_headers => true}
*** User 2024-03-11 09:20:10.935 ***🔗
bob_add_contact_and_invite_2904@localhost/res1 in
<iq from='bob_add_contact_and_invite_2904@localhost' to='bob_add_contact_and_invite_2904@localhost/res1' id='push4c3202f7f6882cc4' type='set'>
<query xmlns='jabber:iq:roster'>
<item subscription='none' jid='alice_add_contact_and_invite_2904@localhost'/>
</query>
</iq>
*** User 2024-03-11 09:20:11.007 ***🔗
REST request:
Code: 200
Req: {<0.80241.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"616d7867cf38f217">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjkwNEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Mon, 11 Mar 2024 09:20:10 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"90">>}],
<<"[{\"ask\":\"none\",\"subscription\":\"none\",\"jid\":\"alice_add_contact_and_invite_2904@localhost\"}]">>,
214,18208}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
method => <<"GET">>,
creds =>
{<<"bob_add_contact_and_invite_2904@localhost">>,
<<"makrolika">>},
body => <<>>,role => client,return_headers => true}
*** User 2024-03-11 09:20:11.090 ***🔗
REST request:
Code: 204
Req: {<0.80271.0>,
<<"/api/contacts/alice_add_contact_and_invite_2904@localhost">>,
<<"PUT">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"5e083fd6c50779c6">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjkwNEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<"{\"action\":\"invite\"}">>}
Result: {{<<"204">>,<<"No Content">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Mon, 11 Mar 2024 09:20:10 GMT">>}],
<<>>,80,59146}
Params: #{path =>
<<"/api/contacts/alice_add_contact_and_invite_2904@localhost">>,
server => #{node => mongooseim@localhost},
method => <<"PUT">>,
creds =>
{<<"bob_add_contact_and_invite_2904@localhost">>,
<<"makrolika">>},
body => <<"{\"action\":\"invite\"}">>,role => client,
return_headers => true}
*** User 2024-03-11 09:20:11.091 ***🔗
bob_add_contact_and_invite_2904@localhost/res1 in
<iq from='bob_add_contact_and_invite_2904@localhost' to='bob_add_contact_and_invite_2904@localhost/res1' id='pushcd9502c741d38d95' type='set'>
<query xmlns='jabber:iq:roster'>
<item ask='subscribe' subscription='none' jid='alice_add_contact_and_invite_2904@localhost'/>
</query>
</iq>
*** User 2024-03-11 09:20:11.091 ***🔗
Push2: {xmlel,<<"iq">>,
[{<<"from">>,<<"bob_add_contact_and_invite_2904@localhost">>},
{<<"to">>,<<"bob_add_contact_and_invite_2904@localhost/res1">>},
{<<"id">>,<<"pushcd9502c741d38d95">>},
{<<"type">>,<<"set">>}],
[{xmlel,<<"query">>,
[{<<"xmlns">>,<<"jabber:iq:roster">>}],
[{xmlel,<<"item">>,
[{<<"ask">>,<<"subscribe">>},
{<<"subscription">>,<<"none">>},
{<<"jid">>,
<<"alice_add_contact_and_invite_2904@localhost">>}],
[]}]}]}
*** User 2024-03-11 09:20:11.091 ***🔗
alice_add_contact_and_invite_2904@localhost/res1 in
<presence from='bob_add_contact_and_invite_2904@localhost' to='alice_add_contact_and_invite_2904@localhost/res1' type='subscribe'/>
*** User 2024-03-11 09:20:11.146 ***🔗
REST request:
Code: 200
Req: {<0.80315.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"ec576dc7405124ac">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjkwNEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Mon, 11 Mar 2024 09:20:10 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"89">>}],
<<"[{\"ask\":\"out\",\"subscription\":\"none\",\"jid\":\"alice_add_contact_and_invite_2904@localhost\"}]">>,
213,24326}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
method => <<"GET">>,
creds =>
{<<"bob_add_contact_and_invite_2904@localhost">>,
<<"makrolika">>},
body => <<>>,role => client,return_headers => true}
*** User 2024-03-11 09:20:11.146 ***🔗
alice_add_contact_and_invite_2904@localhost/res1 out
<iq type='set' id='f4c904b7586563a89f693bce6aeb899c'>
<query xmlns='jabber:iq:roster'>
<item jid='bob_add_contact_and_invite_2904@localhost' name='Bob'/>
</query>
</iq>
*** User 2024-03-11 09:20:11.153 ***🔗
alice_add_contact_and_invite_2904@localhost/res1 in
<iq from='alice_add_contact_and_invite_2904@localhost' to='alice_add_contact_and_invite_2904@localhost/res1' id='push1e2524bdffc03ff1' type='set'>
<query xmlns='jabber:iq:roster'>
<item subscription='none' name='Bob' jid='bob_add_contact_and_invite_2904@localhost'/>
</query>
</iq>
*** User 2024-03-11 09:20:11.153 ***🔗
alice_add_contact_and_invite_2904@localhost/res1 out
<iq to='alice_add_contact_and_invite_2904@localhost' id='push1e2524bdffc03ff1' type='result'/>
*** User 2024-03-11 09:20:11.153 ***🔗
alice_add_contact_and_invite_2904@localhost/res1 in
<iq from='alice_add_contact_and_invite_2904@localhost' to='alice_add_contact_and_invite_2904@localhost/res1' id='f4c904b7586563a89f693bce6aeb899c' type='result'/>
*** User 2024-03-11 09:20:11.153 ***🔗
alice_add_contact_and_invite_2904@localhost/res1 out
<presence type='subscribed' to='bob_add_contact_and_invite_2904@localhost'/>
*** User 2024-03-11 09:20:11.175 ***🔗
bob_add_contact_and_invite_2904@localhost/res1 in
<iq from='bob_add_contact_and_invite_2904@localhost' to='bob_add_contact_and_invite_2904@localhost/res1' id='push3d1a482134e70291' type='set'>
<query xmlns='jabber:iq:roster'>
<item subscription='to' jid='alice_add_contact_and_invite_2904@localhost'/>
</query>
</iq>
*** User 2024-03-11 09:20:11.175 ***🔗
Push3 {xmlel,<<"iq">>,
[{<<"from">>,<<"bob_add_contact_and_invite_2904@localhost">>},
{<<"to">>,<<"bob_add_contact_and_invite_2904@localhost/res1">>},
{<<"id">>,<<"push3d1a482134e70291">>},
{<<"type">>,<<"set">>}],
[{xmlel,<<"query">>,
[{<<"xmlns">>,<<"jabber:iq:roster">>}],
[{xmlel,<<"item">>,
[{<<"subscription">>,<<"to">>},
{<<"jid">>,
<<"alice_add_contact_and_invite_2904@localhost">>}],
[]}]}]}
*** User 2024-03-11 09:20:11.191 ***🔗
REST request:
Code: 200
Req: {<0.80355.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"95928cdc9c4e03ee">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjkwNEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Mon, 11 Mar 2024 09:20:10 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"88">>}],
<<"[{\"ask\":\"none\",\"subscription\":\"to\",\"jid\":\"alice_add_contact_and_invite_2904@localhost\"}]">>,
212,5855}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
method => <<"GET">>,
creds =>
{<<"bob_add_contact_and_invite_2904@localhost">>,
<<"makrolika">>},
body => <<>>,role => client,return_headers => true}
*** User 2024-03-11 09:20:11.191 ***🔗
bob_add_contact_and_invite_2904@localhost/res1 out
</stream:stream>
*** User 2024-03-11 09:20:11.193 ***🔗
bob_add_contact_and_invite_2904@localhost/res1 in
</stream:stream>
*** User 2024-03-11 09:20:11.193 ***🔗
alice_add_contact_and_invite_2904@localhost/res1 out
</stream:stream>
*** User 2024-03-11 09:20:11.203 ***🔗
alice_add_contact_and_invite_2904@localhost/res1 in
</stream:stream>
=== Ended at 2024-03-11 09:20:11
=== successfully completed test case
=== === Returned value: ok