=== Test case: rest_client_SUITE:add_contact_and_invite/1 (click for source code)
=== Config value:
[{watchdog,<0.87325.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@c4570d256f6e.2024-02-22_11.16.10/big_tests.tests.rest_client_SUITE.logs/run.2024-02-22_11.34.02/rest_client_suite.add_contact_and_invite.226306.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@c4570d256f6e.2024-02-22_11.16.10/big_tests.tests.rest_client_SUITE.logs/run.2024-02-22_11.34.02/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_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_cache_users =>
#{strategy => fifo,number_of_segments => 5,time_to_live => 2},
mod_bosh =>
#{backend => mnesia,inactivity => 30,max_pause => 120,
max_wait => infinity,server_acks => false},
mod_carboncopy => #{iqdisc => no_queue}}}]
=== Current directory is "/home/circleci/project/big_tests/ct_report/ct_run.test@c4570d256f6e.2024-02-22_11.16.10"
=== Started at 2024-02-22 11:34:04
*** User 2024-02-22 11:34:04.558 ***🔗
alicE_add_contact_and_invite_3262@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-22 11:34:04.558 ***🔗
alicE_add_contact_and_invite_3262@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='16a156cebcdc33e0' from='localhost' version='1.0' xml:lang='en'>
*** User 2024-02-22 11:34:04.558 ***🔗
alicE_add_contact_and_invite_3262@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-22 11:34:04.559 ***🔗
alicE_add_contact_and_invite_3262@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGFsaWNFX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzI2MgBtYXR5Z3J5c2E=</auth>
*** User 2024-02-22 11:34:04.559 ***🔗
alicE_add_contact_and_invite_3262@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
*** User 2024-02-22 11:34:04.560 ***🔗
alicE_add_contact_and_invite_3262@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-22 11:34:04.560 ***🔗
alicE_add_contact_and_invite_3262@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='c5636c3c0d150f29' from='localhost' version='1.0' xml:lang='en' to='alice_add_contact_and_invite_3262@localhost'>
*** User 2024-02-22 11:34:04.560 ***🔗
alicE_add_contact_and_invite_3262@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-22 11:34:04.560 ***🔗
alicE_add_contact_and_invite_3262@localhost/res1 out
<iq type='set' id='6e1a1f27b53d68ba73ac895a78926861'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<resource>res1</resource>
</bind>
</iq>
*** User 2024-02-22 11:34:04.560 ***🔗
alicE_add_contact_and_invite_3262@localhost/res1 in
<iq id='6e1a1f27b53d68ba73ac895a78926861' type='result'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<jid>alice_add_contact_and_invite_3262@localhost/res1</jid>
</bind>
</iq>
*** User 2024-02-22 11:34:04.560 ***🔗
alice_add_contact_and_invite_3262@localhost/res1 out
<iq type='set' id='65d7aa6683b3c27a009fdadfc3351af0'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-02-22 11:34:04.561 ***🔗
alice_add_contact_and_invite_3262@localhost/res1 in
<iq from='localhost' to='alice_add_contact_and_invite_3262@localhost/res1' id='65d7aa6683b3c27a009fdadfc3351af0' type='result'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-02-22 11:34:04.561 ***🔗
alice_add_contact_and_invite_3262@localhost/res1 out
<presence/>
*** User 2024-02-22 11:34:04.562 ***🔗
alice_add_contact_and_invite_3262@localhost/res1 in
<presence from='alice_add_contact_and_invite_3262@localhost/res1' to='alice_add_contact_and_invite_3262@localhost/res1'/>
*** User 2024-02-22 11:34:04.563 ***🔗
bOb_add_contact_and_invite_3262@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-22 11:34:04.563 ***🔗
bOb_add_contact_and_invite_3262@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='db25a99d16c12d99' from='localhost' version='1.0' xml:lang='en'>
*** User 2024-02-22 11:34:04.563 ***🔗
bOb_add_contact_and_invite_3262@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-22 11:34:04.564 ***🔗
bOb_add_contact_and_invite_3262@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGJPYl9hZGRfY29udGFjdF9hbmRfaW52aXRlXzMyNjIAbWFrcm9saWth</auth>
*** User 2024-02-22 11:34:04.564 ***🔗
bOb_add_contact_and_invite_3262@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
*** User 2024-02-22 11:34:04.564 ***🔗
bOb_add_contact_and_invite_3262@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-22 11:34:04.565 ***🔗
bOb_add_contact_and_invite_3262@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='df9aa8b52613f4e6' from='localhost' version='1.0' xml:lang='en' to='bob_add_contact_and_invite_3262@localhost'>
*** User 2024-02-22 11:34:04.565 ***🔗
bOb_add_contact_and_invite_3262@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-22 11:34:04.565 ***🔗
bOb_add_contact_and_invite_3262@localhost/res1 out
<iq type='set' id='16c25802d1a83a6ae10465939e19871b'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<resource>res1</resource>
</bind>
</iq>
*** User 2024-02-22 11:34:04.565 ***🔗
bOb_add_contact_and_invite_3262@localhost/res1 in
<iq id='16c25802d1a83a6ae10465939e19871b' type='result'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<jid>bob_add_contact_and_invite_3262@localhost/res1</jid>
</bind>
</iq>
*** User 2024-02-22 11:34:04.565 ***🔗
bob_add_contact_and_invite_3262@localhost/res1 out
<iq type='set' id='743aa3a44f4bf9079105efdd3719be23'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-02-22 11:34:04.566 ***🔗
bob_add_contact_and_invite_3262@localhost/res1 in
<iq from='localhost' to='bob_add_contact_and_invite_3262@localhost/res1' id='743aa3a44f4bf9079105efdd3719be23' type='result'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-02-22 11:34:04.566 ***🔗
bob_add_contact_and_invite_3262@localhost/res1 out
<presence/>
*** User 2024-02-22 11:34:04.567 ***🔗
bob_add_contact_and_invite_3262@localhost/res1 in
<presence from='bob_add_contact_and_invite_3262@localhost/res1' to='bob_add_contact_and_invite_3262@localhost/res1'/>
*** User 2024-02-22 11:34:04.578 ***🔗
REST request:
Code: 200
Req: {<0.87389.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"fbbe32baffef8f33">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzI2MkBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 22 Feb 2024 11:34:04 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"2">>}],
<<"[]">>,125,5586}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
method => <<"GET">>,
creds =>
{<<"bob_add_contact_and_invite_3262@localhost">>,
<<"makrolika">>},
body => <<>>,role => client,return_headers => true}
*** User 2024-02-22 11:34:04.589 ***🔗
REST request:
Code: 204
Req: {<0.87422.0>,<<"/api/contacts">>,<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"5e01cf26c3dbf027">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzI2MkBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<"{\"jid\":\"alice_add_contact_and_invite_3262@localhost\"}">>}
Result: {{<<"204">>,<<"No Content">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 22 Feb 2024 11:34:04 GMT">>}],
<<>>,80,4654}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
method => <<"POST">>,
creds =>
{<<"bob_add_contact_and_invite_3262@localhost">>,
<<"makrolika">>},
body =>
<<"{\"jid\":\"alice_add_contact_and_invite_3262@localhost\"}">>,
role => client,return_headers => true}
*** User 2024-02-22 11:34:04.589 ***🔗
bob_add_contact_and_invite_3262@localhost/res1 in
<iq from='bob_add_contact_and_invite_3262@localhost' to='bob_add_contact_and_invite_3262@localhost/res1' id='pushc6f72f638540c2a4' type='set'>
<query xmlns='jabber:iq:roster'>
<item subscription='none' jid='alice_add_contact_and_invite_3262@localhost'/>
</query>
</iq>
*** User 2024-02-22 11:34:04.646 ***🔗
REST request:
Code: 200
Req: {<0.87454.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"275db7fd39b55ffb">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzI2MkBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 22 Feb 2024 11:34:04 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"90">>}],
<<"[{\"ask\":\"none\",\"subscription\":\"none\",\"jid\":\"alice_add_contact_and_invite_3262@localhost\"}]">>,
214,9569}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
method => <<"GET">>,
creds =>
{<<"bob_add_contact_and_invite_3262@localhost">>,
<<"makrolika">>},
body => <<>>,role => client,return_headers => true}
*** User 2024-02-22 11:34:04.658 ***🔗
REST request:
Code: 204
Req: {<0.87496.0>,
<<"/api/contacts/alice_add_contact_and_invite_3262@localhost">>,
<<"PUT">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"5b9e4d0964dadc3d">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzI2MkBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<"{\"action\":\"invite\"}">>}
Result: {{<<"204">>,<<"No Content">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 22 Feb 2024 11:34:04 GMT">>}],
<<>>,80,7815}
Params: #{path =>
<<"/api/contacts/alice_add_contact_and_invite_3262@localhost">>,
server => #{node => mongooseim@localhost},
method => <<"PUT">>,
creds =>
{<<"bob_add_contact_and_invite_3262@localhost">>,
<<"makrolika">>},
body => <<"{\"action\":\"invite\"}">>,role => client,
return_headers => true}
*** User 2024-02-22 11:34:04.658 ***🔗
bob_add_contact_and_invite_3262@localhost/res1 in
<iq from='bob_add_contact_and_invite_3262@localhost' to='bob_add_contact_and_invite_3262@localhost/res1' id='pushcaaa5d226ec8eee7' type='set'>
<query xmlns='jabber:iq:roster'>
<item ask='subscribe' subscription='none' jid='alice_add_contact_and_invite_3262@localhost'/>
</query>
</iq>
*** User 2024-02-22 11:34:04.658 ***🔗
Push2: {xmlel,<<"iq">>,
[{<<"from">>,<<"bob_add_contact_and_invite_3262@localhost">>},
{<<"to">>,<<"bob_add_contact_and_invite_3262@localhost/res1">>},
{<<"id">>,<<"pushcaaa5d226ec8eee7">>},
{<<"type">>,<<"set">>}],
[{xmlel,<<"query">>,
[{<<"xmlns">>,<<"jabber:iq:roster">>}],
[{xmlel,<<"item">>,
[{<<"ask">>,<<"subscribe">>},
{<<"subscription">>,<<"none">>},
{<<"jid">>,
<<"alice_add_contact_and_invite_3262@localhost">>}],
[]}]}]}
*** User 2024-02-22 11:34:04.658 ***🔗
alice_add_contact_and_invite_3262@localhost/res1 in
<presence from='bob_add_contact_and_invite_3262@localhost' to='alice_add_contact_and_invite_3262@localhost/res1' type='subscribe'/>
*** User 2024-02-22 11:34:04.666 ***🔗
REST request:
Code: 200
Req: {<0.87549.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"7058e82b7158e88e">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzI2MkBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 22 Feb 2024 11:34:04 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"89">>}],
<<"[{\"ask\":\"out\",\"subscription\":\"none\",\"jid\":\"alice_add_contact_and_invite_3262@localhost\"}]">>,
213,3859}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
method => <<"GET">>,
creds =>
{<<"bob_add_contact_and_invite_3262@localhost">>,
<<"makrolika">>},
body => <<>>,role => client,return_headers => true}
*** User 2024-02-22 11:34:04.667 ***🔗
alice_add_contact_and_invite_3262@localhost/res1 out
<iq type='set' id='3d5a247ac071eef22a05268320c7c54e'>
<query xmlns='jabber:iq:roster'>
<item jid='bob_add_contact_and_invite_3262@localhost' name='Bob'/>
</query>
</iq>
*** User 2024-02-22 11:34:04.670 ***🔗
alice_add_contact_and_invite_3262@localhost/res1 in
<iq from='alice_add_contact_and_invite_3262@localhost' to='alice_add_contact_and_invite_3262@localhost/res1' id='pushdbf26b84a68ae128' type='set'>
<query xmlns='jabber:iq:roster'>
<item subscription='none' name='Bob' jid='bob_add_contact_and_invite_3262@localhost'/>
</query>
</iq>
*** User 2024-02-22 11:34:04.670 ***🔗
alice_add_contact_and_invite_3262@localhost/res1 out
<iq to='alice_add_contact_and_invite_3262@localhost' id='pushdbf26b84a68ae128' type='result'/>
*** User 2024-02-22 11:34:04.670 ***🔗
alice_add_contact_and_invite_3262@localhost/res1 in
<iq from='alice_add_contact_and_invite_3262@localhost' to='alice_add_contact_and_invite_3262@localhost/res1' id='3d5a247ac071eef22a05268320c7c54e' type='result'/>
*** User 2024-02-22 11:34:04.670 ***🔗
alice_add_contact_and_invite_3262@localhost/res1 out
<presence type='subscribed' to='bob_add_contact_and_invite_3262@localhost'/>
*** User 2024-02-22 11:34:04.676 ***🔗
bob_add_contact_and_invite_3262@localhost/res1 in
<iq from='bob_add_contact_and_invite_3262@localhost' to='bob_add_contact_and_invite_3262@localhost/res1' id='pushd40acc725fd72cef' type='set'>
<query xmlns='jabber:iq:roster'>
<item subscription='to' jid='alice_add_contact_and_invite_3262@localhost'/>
</query>
</iq>
*** User 2024-02-22 11:34:04.676 ***🔗
Push3 {xmlel,<<"iq">>,
[{<<"from">>,<<"bob_add_contact_and_invite_3262@localhost">>},
{<<"to">>,<<"bob_add_contact_and_invite_3262@localhost/res1">>},
{<<"id">>,<<"pushd40acc725fd72cef">>},
{<<"type">>,<<"set">>}],
[{xmlel,<<"query">>,
[{<<"xmlns">>,<<"jabber:iq:roster">>}],
[{xmlel,<<"item">>,
[{<<"subscription">>,<<"to">>},
{<<"jid">>,
<<"alice_add_contact_and_invite_3262@localhost">>}],
[]}]}]}
*** User 2024-02-22 11:34:04.743 ***🔗
REST request:
Code: 200
Req: {<0.87585.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"8134bfc8ca893bb8">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMzI2MkBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 22 Feb 2024 11:34:04 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"88">>}],
<<"[{\"ask\":\"none\",\"subscription\":\"to\",\"jid\":\"alice_add_contact_and_invite_3262@localhost\"}]">>,
212,62476}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
method => <<"GET">>,
creds =>
{<<"bob_add_contact_and_invite_3262@localhost">>,
<<"makrolika">>},
body => <<>>,role => client,return_headers => true}
*** User 2024-02-22 11:34:04.744 ***🔗
bob_add_contact_and_invite_3262@localhost/res1 out
</stream:stream>
*** User 2024-02-22 11:34:04.744 ***🔗
bob_add_contact_and_invite_3262@localhost/res1 in
</stream:stream>
*** User 2024-02-22 11:34:04.744 ***🔗
alice_add_contact_and_invite_3262@localhost/res1 out
</stream:stream>
*** User 2024-02-22 11:34:04.744 ***🔗
alice_add_contact_and_invite_3262@localhost/res1 in
</stream:stream>
=== Ended at 2024-02-22 11:34:04
=== successfully completed test case
=== === Returned value: ok