=== Test case: rest_client_SUITE:add_contact_and_invite/1 (click for source code)
=== Config value:
[{watchdog,<0.105726.0>},
{muc_light_host,<<"muclight.localhost">>},
{mam_backend,rdbms},
{preset,"odbc_mssql_mnesia"},
{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@d67ced1141dd.2024-04-16_10.12.40/big_tests.tests.rest_client_SUITE.logs/run.2024-04-16_10.31.23/rest_client_suite.add_contact_and_invite.235139.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@d67ced1141dd.2024-04-16_10.12.40/big_tests.tests.rest_client_SUITE.logs/run.2024-04-16_10.31.23/log_private/"},
{{saved_modules,mongooseim@localhost,<<"localhost">>},
#{mod_vcard =>
#{matches => 30,
host => {prefix,<<"vjud.">>},
search => true,iqdisc => parallel,backend => rdbms},
mod_roster =>
#{iqdisc => one_queue,backend => rdbms,versioning => false,
store_current_id => false},
mod_sic => #{iqdisc => one_queue},
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_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,buffer_max => 100,
ack_freq => 1,
stale_h =>
#{enabled => false,repeat_after => 1800,geriatric => 3600},
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@d67ced1141dd.2024-04-16_10.12.40"
=== Started at 2024-04-16 10:31:25
*** User 2024-04-16 10:31:25.898 ***🔗
alicE_add_contact_and_invite_4190@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-04-16 10:31:25.899 ***🔗
alicE_add_contact_and_invite_4190@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='c0190b6b2be35464' from='localhost' version='1.0' xml:lang='en'>
*** User 2024-04-16 10:31:25.899 ***🔗
alicE_add_contact_and_invite_4190@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-04-16 10:31:25.899 ***🔗
alicE_add_contact_and_invite_4190@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGFsaWNFX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfNDE5MABtYXR5Z3J5c2E=</auth>
*** User 2024-04-16 10:31:25.900 ***🔗
alicE_add_contact_and_invite_4190@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
*** User 2024-04-16 10:31:25.900 ***🔗
alicE_add_contact_and_invite_4190@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-04-16 10:31:25.900 ***🔗
alicE_add_contact_and_invite_4190@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='ae8cbed1331d0aec' from='localhost' version='1.0' xml:lang='en' to='alice_add_contact_and_invite_4190@localhost'>
*** User 2024-04-16 10:31:25.900 ***🔗
alicE_add_contact_and_invite_4190@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-04-16 10:31:25.900 ***🔗
alicE_add_contact_and_invite_4190@localhost/res1 out
<iq type='set' id='87e93b1edd04543d0fefe59d8eb3a293'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<resource>res1</resource>
</bind>
</iq>
*** User 2024-04-16 10:31:25.901 ***🔗
alicE_add_contact_and_invite_4190@localhost/res1 in
<iq id='87e93b1edd04543d0fefe59d8eb3a293' type='result'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<jid>alice_add_contact_and_invite_4190@localhost/res1</jid>
</bind>
</iq>
*** User 2024-04-16 10:31:25.901 ***🔗
alice_add_contact_and_invite_4190@localhost/res1 out
<iq type='set' id='df5918ace4104fb40b76587931d10a28'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-04-16 10:31:25.901 ***🔗
alice_add_contact_and_invite_4190@localhost/res1 in
<iq from='localhost' to='alice_add_contact_and_invite_4190@localhost/res1' id='df5918ace4104fb40b76587931d10a28' type='result'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-04-16 10:31:25.901 ***🔗
alice_add_contact_and_invite_4190@localhost/res1 out
<presence/>
*** User 2024-04-16 10:31:25.904 ***🔗
alice_add_contact_and_invite_4190@localhost/res1 in
<presence from='alice_add_contact_and_invite_4190@localhost/res1' to='alice_add_contact_and_invite_4190@localhost/res1'/>
*** User 2024-04-16 10:31:25.904 ***🔗
bOb_add_contact_and_invite_4190@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-04-16 10:31:25.905 ***🔗
bOb_add_contact_and_invite_4190@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='4ecdec5b9917f499' from='localhost' version='1.0' xml:lang='en'>
*** User 2024-04-16 10:31:25.905 ***🔗
bOb_add_contact_and_invite_4190@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-04-16 10:31:25.905 ***🔗
bOb_add_contact_and_invite_4190@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGJPYl9hZGRfY29udGFjdF9hbmRfaW52aXRlXzQxOTAAbWFrcm9saWth</auth>
*** User 2024-04-16 10:31:25.906 ***🔗
bOb_add_contact_and_invite_4190@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
*** User 2024-04-16 10:31:25.906 ***🔗
bOb_add_contact_and_invite_4190@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-04-16 10:31:25.906 ***🔗
bOb_add_contact_and_invite_4190@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='fe3e005259584362' from='localhost' version='1.0' xml:lang='en' to='bob_add_contact_and_invite_4190@localhost'>
*** User 2024-04-16 10:31:25.907 ***🔗
bOb_add_contact_and_invite_4190@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-04-16 10:31:25.907 ***🔗
bOb_add_contact_and_invite_4190@localhost/res1 out
<iq type='set' id='f651bad91c9711d1fd032ebd22d1c00d'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<resource>res1</resource>
</bind>
</iq>
*** User 2024-04-16 10:31:25.907 ***🔗
bOb_add_contact_and_invite_4190@localhost/res1 in
<iq id='f651bad91c9711d1fd032ebd22d1c00d' type='result'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<jid>bob_add_contact_and_invite_4190@localhost/res1</jid>
</bind>
</iq>
*** User 2024-04-16 10:31:25.907 ***🔗
bob_add_contact_and_invite_4190@localhost/res1 out
<iq type='set' id='757aa048e8c0640bda3914c9a917e99e'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-04-16 10:31:25.908 ***🔗
bob_add_contact_and_invite_4190@localhost/res1 in
<iq from='localhost' to='bob_add_contact_and_invite_4190@localhost/res1' id='757aa048e8c0640bda3914c9a917e99e' type='result'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-04-16 10:31:25.908 ***🔗
bob_add_contact_and_invite_4190@localhost/res1 out
<presence/>
*** User 2024-04-16 10:31:25.909 ***🔗
bob_add_contact_and_invite_4190@localhost/res1 in
<presence from='bob_add_contact_and_invite_4190@localhost/res1' to='bob_add_contact_and_invite_4190@localhost/res1'/>
*** User 2024-04-16 10:31:25.919 ***🔗
REST request:
Code: 200
Req: {<0.105802.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"86bf7ead9cbd26b4">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfNDE5MEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 16 Apr 2024 10:31:25 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"2">>}],
<<"[]">>,125,4048}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
creds =>
{<<"bob_add_contact_and_invite_4190@localhost">>,
<<"makrolika">>},
body => <<>>,role => client,method => <<"GET">>,
return_headers => true}
*** User 2024-04-16 10:31:25.969 ***🔗
REST request:
Code: 204
Req: {<0.105825.0>,<<"/api/contacts">>,<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"45667bbd87c0edad">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfNDE5MEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<"{\"jid\":\"alice_add_contact_and_invite_4190@localhost\"}">>}
Result: {{<<"204">>,<<"No Content">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 16 Apr 2024 10:31:25 GMT">>}],
<<>>,80,44385}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
creds =>
{<<"bob_add_contact_and_invite_4190@localhost">>,
<<"makrolika">>},
body =>
<<"{\"jid\":\"alice_add_contact_and_invite_4190@localhost\"}">>,
role => client,method => <<"POST">>,return_headers => true}
*** User 2024-04-16 10:31:25.970 ***🔗
bob_add_contact_and_invite_4190@localhost/res1 in
<iq from='bob_add_contact_and_invite_4190@localhost' to='bob_add_contact_and_invite_4190@localhost/res1' id='pushbb676ee25cb6dff3' type='set'>
<query xmlns='jabber:iq:roster'>
<item jid='alice_add_contact_and_invite_4190@localhost' subscription='none'/>
</query>
</iq>
*** User 2024-04-16 10:31:25.982 ***🔗
REST request:
Code: 200
Req: {<0.105859.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"3a885f86d8701088">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfNDE5MEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 16 Apr 2024 10:31:25 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"90">>}],
<<"[{\"ask\":\"none\",\"subscription\":\"none\",\"jid\":\"alice_add_contact_and_invite_4190@localhost\"}]">>,
214,6481}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
creds =>
{<<"bob_add_contact_and_invite_4190@localhost">>,
<<"makrolika">>},
body => <<>>,role => client,method => <<"GET">>,
return_headers => true}
*** User 2024-04-16 10:31:26.077 ***🔗
REST request:
Code: 204
Req: {<0.105901.0>,
<<"/api/contacts/alice_add_contact_and_invite_4190@localhost">>,
<<"PUT">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"14c157cc5f8f48c3">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfNDE5MEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<"{\"action\":\"invite\"}">>}
Result: {{<<"204">>,<<"No Content">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 16 Apr 2024 10:31:25 GMT">>}],
<<>>,80,85966}
Params: #{path =>
<<"/api/contacts/alice_add_contact_and_invite_4190@localhost">>,
server => #{node => mongooseim@localhost},
creds =>
{<<"bob_add_contact_and_invite_4190@localhost">>,
<<"makrolika">>},
body => <<"{\"action\":\"invite\"}">>,role => client,
method => <<"PUT">>,return_headers => true}
*** User 2024-04-16 10:31:26.077 ***🔗
bob_add_contact_and_invite_4190@localhost/res1 in
<iq from='bob_add_contact_and_invite_4190@localhost' to='bob_add_contact_and_invite_4190@localhost/res1' id='push1b1dc40742ed7bd3' type='set'>
<query xmlns='jabber:iq:roster'>
<item ask='subscribe' jid='alice_add_contact_and_invite_4190@localhost' subscription='none'/>
</query>
</iq>
*** User 2024-04-16 10:31:26.077 ***🔗
Push2: {xmlel,<<"iq">>,
[{<<"from">>,<<"bob_add_contact_and_invite_4190@localhost">>},
{<<"to">>,<<"bob_add_contact_and_invite_4190@localhost/res1">>},
{<<"id">>,<<"push1b1dc40742ed7bd3">>},
{<<"type">>,<<"set">>}],
[{xmlel,<<"query">>,
[{<<"xmlns">>,<<"jabber:iq:roster">>}],
[{xmlel,<<"item">>,
[{<<"ask">>,<<"subscribe">>},
{<<"jid">>,
<<"alice_add_contact_and_invite_4190@localhost">>},
{<<"subscription">>,<<"none">>}],
[]}]}]}
*** User 2024-04-16 10:31:26.077 ***🔗
alice_add_contact_and_invite_4190@localhost/res1 in
<presence from='bob_add_contact_and_invite_4190@localhost' to='alice_add_contact_and_invite_4190@localhost/res1' type='subscribe'/>
*** User 2024-04-16 10:31:26.087 ***🔗
REST request:
Code: 200
Req: {<0.105965.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"726ad02a19a0d154">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfNDE5MEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 16 Apr 2024 10:31:25 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"89">>}],
<<"[{\"ask\":\"out\",\"subscription\":\"none\",\"jid\":\"alice_add_contact_and_invite_4190@localhost\"}]">>,
213,4085}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
creds =>
{<<"bob_add_contact_and_invite_4190@localhost">>,
<<"makrolika">>},
body => <<>>,role => client,method => <<"GET">>,
return_headers => true}
*** User 2024-04-16 10:31:26.088 ***🔗
alice_add_contact_and_invite_4190@localhost/res1 out
<iq type='set' id='b9d729740f4feaa02ef00061ceb9b5a6'>
<query xmlns='jabber:iq:roster'>
<item jid='bob_add_contact_and_invite_4190@localhost' name='Bob'/>
</query>
</iq>
*** User 2024-04-16 10:31:26.092 ***🔗
alice_add_contact_and_invite_4190@localhost/res1 in
<iq from='alice_add_contact_and_invite_4190@localhost' to='alice_add_contact_and_invite_4190@localhost/res1' id='pushb6f541f4552b4a54' type='set'>
<query xmlns='jabber:iq:roster'>
<item name='Bob' jid='bob_add_contact_and_invite_4190@localhost' subscription='none'/>
</query>
</iq>
*** User 2024-04-16 10:31:26.092 ***🔗
alice_add_contact_and_invite_4190@localhost/res1 out
<iq to='alice_add_contact_and_invite_4190@localhost' id='pushb6f541f4552b4a54' type='result'/>
*** User 2024-04-16 10:31:26.092 ***🔗
alice_add_contact_and_invite_4190@localhost/res1 in
<iq from='alice_add_contact_and_invite_4190@localhost' to='alice_add_contact_and_invite_4190@localhost/res1' id='b9d729740f4feaa02ef00061ceb9b5a6' type='result'/>
*** User 2024-04-16 10:31:26.092 ***🔗
alice_add_contact_and_invite_4190@localhost/res1 out
<presence type='subscribed' to='bob_add_contact_and_invite_4190@localhost'/>
*** User 2024-04-16 10:31:26.100 ***🔗
bob_add_contact_and_invite_4190@localhost/res1 in
<iq from='bob_add_contact_and_invite_4190@localhost' to='bob_add_contact_and_invite_4190@localhost/res1' id='pushaf0126e0a9b2576b' type='set'>
<query xmlns='jabber:iq:roster'>
<item jid='alice_add_contact_and_invite_4190@localhost' subscription='to'/>
</query>
</iq>
*** User 2024-04-16 10:31:26.100 ***🔗
Push3 {xmlel,<<"iq">>,
[{<<"from">>,<<"bob_add_contact_and_invite_4190@localhost">>},
{<<"to">>,<<"bob_add_contact_and_invite_4190@localhost/res1">>},
{<<"id">>,<<"pushaf0126e0a9b2576b">>},
{<<"type">>,<<"set">>}],
[{xmlel,<<"query">>,
[{<<"xmlns">>,<<"jabber:iq:roster">>}],
[{xmlel,<<"item">>,
[{<<"jid">>,
<<"alice_add_contact_and_invite_4190@localhost">>},
{<<"subscription">>,<<"to">>}],
[]}]}]}
*** User 2024-04-16 10:31:26.109 ***🔗
REST request:
Code: 200
Req: {<0.105989.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"e9e824b59d922884">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfNDE5MEBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Tue, 16 Apr 2024 10:31:25 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"88">>}],
<<"[{\"ask\":\"none\",\"subscription\":\"to\",\"jid\":\"alice_add_contact_and_invite_4190@localhost\"}]">>,
212,3700}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
creds =>
{<<"bob_add_contact_and_invite_4190@localhost">>,
<<"makrolika">>},
body => <<>>,role => client,method => <<"GET">>,
return_headers => true}
*** User 2024-04-16 10:31:26.109 ***🔗
bob_add_contact_and_invite_4190@localhost/res1 out
</stream:stream>
*** User 2024-04-16 10:31:26.109 ***🔗
bob_add_contact_and_invite_4190@localhost/res1 in
</stream:stream>
*** User 2024-04-16 10:31:26.109 ***🔗
alice_add_contact_and_invite_4190@localhost/res1 out
</stream:stream>
*** User 2024-04-16 10:31:26.110 ***🔗
alice_add_contact_and_invite_4190@localhost/res1 in
</stream:stream>
=== Ended at 2024-04-16 10:31:26
=== successfully completed test case
=== === Returned value: ok