=== Test case: rest_client_SUITE:add_contact_and_invite/1 (click for source code)
=== Config value:
[{watchdog,<0.82633.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@55a9538c7bf7.2024-04-25_14.32.29/big_tests.tests.rest_client_SUITE.logs/run.2024-04-25_14.46.45/rest_client_suite.add_contact_and_invite.138755.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@55a9538c7bf7.2024-04-25_14.32.29/big_tests.tests.rest_client_SUITE.logs/run.2024-04-25_14.46.45/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_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_amp => #{},
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_cache_users =>
#{strategy => fifo,number_of_segments => 5,time_to_live => 2},
mod_bosh =>
#{backend => cets,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@55a9538c7bf7.2024-04-25_14.32.29"
=== Started at 2024-04-25 14:46:47
*** User 2024-04-25 14:46:47.686 ***🔗
alicE_add_contact_and_invite_2995@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-25 14:46:47.687 ***🔗
alicE_add_contact_and_invite_2995@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='1df2c50ffb56469f' from='localhost' version='1.0' xml:lang='en'>
*** User 2024-04-25 14:46:47.687 ***🔗
alicE_add_contact_and_invite_2995@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-25 14:46:47.687 ***🔗
alicE_add_contact_and_invite_2995@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGFsaWNFX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjk5NQBtYXR5Z3J5c2E=</auth>
*** User 2024-04-25 14:46:47.692 ***🔗
alicE_add_contact_and_invite_2995@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
*** User 2024-04-25 14:46:47.692 ***🔗
alicE_add_contact_and_invite_2995@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-25 14:46:47.693 ***🔗
alicE_add_contact_and_invite_2995@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='61406fe1a4f12845' from='localhost' version='1.0' xml:lang='en' to='alice_add_contact_and_invite_2995@localhost'>
*** User 2024-04-25 14:46:47.693 ***🔗
alicE_add_contact_and_invite_2995@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-25 14:46:47.693 ***🔗
alicE_add_contact_and_invite_2995@localhost/res1 out
<iq type='set' id='8df369f7abae0d6c164697a745ee9f24'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<resource>res1</resource>
</bind>
</iq>
*** User 2024-04-25 14:46:47.694 ***🔗
alicE_add_contact_and_invite_2995@localhost/res1 in
<iq id='8df369f7abae0d6c164697a745ee9f24' type='result'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<jid>alice_add_contact_and_invite_2995@localhost/res1</jid>
</bind>
</iq>
*** User 2024-04-25 14:46:47.694 ***🔗
alice_add_contact_and_invite_2995@localhost/res1 out
<iq type='set' id='0f3856f776d6bfe1eb55d5421ca15e15'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-04-25 14:46:47.695 ***🔗
alice_add_contact_and_invite_2995@localhost/res1 in
<iq from='localhost' to='alice_add_contact_and_invite_2995@localhost/res1' id='0f3856f776d6bfe1eb55d5421ca15e15' type='result'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-04-25 14:46:47.695 ***🔗
alice_add_contact_and_invite_2995@localhost/res1 out
<presence/>
*** User 2024-04-25 14:46:47.697 ***🔗
alice_add_contact_and_invite_2995@localhost/res1 in
<presence from='alice_add_contact_and_invite_2995@localhost/res1' to='alice_add_contact_and_invite_2995@localhost/res1'/>
*** User 2024-04-25 14:46:47.697 ***🔗
bOb_add_contact_and_invite_2995@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-25 14:46:47.698 ***🔗
bOb_add_contact_and_invite_2995@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='01103f6a6a387257' from='localhost' version='1.0' xml:lang='en'>
*** User 2024-04-25 14:46:47.698 ***🔗
bOb_add_contact_and_invite_2995@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-25 14:46:47.698 ***🔗
bOb_add_contact_and_invite_2995@localhost/res1 out
<auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl' mechanism='PLAIN'>AGJPYl9hZGRfY29udGFjdF9hbmRfaW52aXRlXzI5OTUAbWFrcm9saWth</auth>
*** User 2024-04-25 14:46:47.699 ***🔗
bOb_add_contact_and_invite_2995@localhost/res1 in
<success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
*** User 2024-04-25 14:46:47.699 ***🔗
bOb_add_contact_and_invite_2995@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-25 14:46:47.699 ***🔗
bOb_add_contact_and_invite_2995@localhost/res1 in
<stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='3e99d39071de4764' from='localhost' version='1.0' xml:lang='en' to='bob_add_contact_and_invite_2995@localhost'>
*** User 2024-04-25 14:46:47.699 ***🔗
bOb_add_contact_and_invite_2995@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-25 14:46:47.699 ***🔗
bOb_add_contact_and_invite_2995@localhost/res1 out
<iq type='set' id='e9ab543af6dea653479f6cf454f229c0'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<resource>res1</resource>
</bind>
</iq>
*** User 2024-04-25 14:46:47.700 ***🔗
bOb_add_contact_and_invite_2995@localhost/res1 in
<iq id='e9ab543af6dea653479f6cf454f229c0' type='result'>
<bind xmlns='urn:ietf:params:xml:ns:xmpp-bind'>
<jid>bob_add_contact_and_invite_2995@localhost/res1</jid>
</bind>
</iq>
*** User 2024-04-25 14:46:47.700 ***🔗
bob_add_contact_and_invite_2995@localhost/res1 out
<iq type='set' id='b681ca02ddd59bd023697b7e85d99edd'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-04-25 14:46:47.701 ***🔗
bob_add_contact_and_invite_2995@localhost/res1 in
<iq from='localhost' to='bob_add_contact_and_invite_2995@localhost/res1' id='b681ca02ddd59bd023697b7e85d99edd' type='result'>
<session xmlns='urn:ietf:params:xml:ns:xmpp-session'/>
</iq>
*** User 2024-04-25 14:46:47.701 ***🔗
bob_add_contact_and_invite_2995@localhost/res1 out
<presence/>
*** User 2024-04-25 14:46:47.703 ***🔗
bob_add_contact_and_invite_2995@localhost/res1 in
<presence from='bob_add_contact_and_invite_2995@localhost/res1' to='bob_add_contact_and_invite_2995@localhost/res1'/>
*** User 2024-04-25 14:46:47.714 ***🔗
REST request:
Code: 200
Req: {<0.82699.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"c24a523b12fc00fe">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjk5NUBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 25 Apr 2024 14:46:47 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"2">>}],
<<"[]">>,125,4724}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
body => <<>>,method => <<"GET">>,role => client,
creds =>
{<<"bob_add_contact_and_invite_2995@localhost">>,
<<"makrolika">>},
return_headers => true}
*** User 2024-04-25 14:46:47.737 ***🔗
REST request:
Code: 204
Req: {<0.82726.0>,<<"/api/contacts">>,<<"POST">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"6aec845523037385">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjk5NUBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<"{\"jid\":\"alice_add_contact_and_invite_2995@localhost\"}">>}
Result: {{<<"204">>,<<"No Content">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 25 Apr 2024 14:46:47 GMT">>}],
<<>>,80,7076}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
body =>
<<"{\"jid\":\"alice_add_contact_and_invite_2995@localhost\"}">>,
method => <<"POST">>,role => client,
creds =>
{<<"bob_add_contact_and_invite_2995@localhost">>,
<<"makrolika">>},
return_headers => true}
*** User 2024-04-25 14:46:47.737 ***🔗
bob_add_contact_and_invite_2995@localhost/res1 in
<iq from='bob_add_contact_and_invite_2995@localhost' to='bob_add_contact_and_invite_2995@localhost/res1' id='push43e9f9f06586984e' type='set'>
<query xmlns='jabber:iq:roster'>
<item jid='alice_add_contact_and_invite_2995@localhost' subscription='none'/>
</query>
</iq>
*** User 2024-04-25 14:46:47.759 ***🔗
REST request:
Code: 200
Req: {<0.82756.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"ac2b80745513f7a0">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjk5NUBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 25 Apr 2024 14:46:47 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"90">>}],
<<"[{\"ask\":\"none\",\"subscription\":\"none\",\"jid\":\"alice_add_contact_and_invite_2995@localhost\"}]">>,
214,14014}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
body => <<>>,method => <<"GET">>,role => client,
creds =>
{<<"bob_add_contact_and_invite_2995@localhost">>,
<<"makrolika">>},
return_headers => true}
*** User 2024-04-25 14:46:47.771 ***🔗
REST request:
Code: 204
Req: {<0.82812.0>,
<<"/api/contacts/alice_add_contact_and_invite_2995@localhost">>,
<<"PUT">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"c67e44d4dee49319">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjk5NUBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<"{\"action\":\"invite\"}">>}
Result: {{<<"204">>,<<"No Content">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 25 Apr 2024 14:46:47 GMT">>}],
<<>>,80,5507}
Params: #{path =>
<<"/api/contacts/alice_add_contact_and_invite_2995@localhost">>,
server => #{node => mongooseim@localhost},
body => <<"{\"action\":\"invite\"}">>,method => <<"PUT">>,
role => client,
creds =>
{<<"bob_add_contact_and_invite_2995@localhost">>,
<<"makrolika">>},
return_headers => true}
*** User 2024-04-25 14:46:47.771 ***🔗
bob_add_contact_and_invite_2995@localhost/res1 in
<iq from='bob_add_contact_and_invite_2995@localhost' to='bob_add_contact_and_invite_2995@localhost/res1' id='push02519d1e203e5104' type='set'>
<query xmlns='jabber:iq:roster'>
<item ask='subscribe' jid='alice_add_contact_and_invite_2995@localhost' subscription='none'/>
</query>
</iq>
*** User 2024-04-25 14:46:47.772 ***🔗
Push2: {xmlel,<<"iq">>,
[{<<"from">>,<<"bob_add_contact_and_invite_2995@localhost">>},
{<<"to">>,<<"bob_add_contact_and_invite_2995@localhost/res1">>},
{<<"id">>,<<"push02519d1e203e5104">>},
{<<"type">>,<<"set">>}],
[{xmlel,<<"query">>,
[{<<"xmlns">>,<<"jabber:iq:roster">>}],
[{xmlel,<<"item">>,
[{<<"ask">>,<<"subscribe">>},
{<<"jid">>,
<<"alice_add_contact_and_invite_2995@localhost">>},
{<<"subscription">>,<<"none">>}],
[]}]}]}
*** User 2024-04-25 14:46:47.772 ***🔗
alice_add_contact_and_invite_2995@localhost/res1 in
<presence from='bob_add_contact_and_invite_2995@localhost' to='alice_add_contact_and_invite_2995@localhost/res1' type='subscribe'/>
*** User 2024-04-25 14:46:47.810 ***🔗
REST request:
Code: 200
Req: {<0.82850.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"df12a6ce75321642">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjk5NUBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 25 Apr 2024 14:46:47 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"89">>}],
<<"[{\"ask\":\"out\",\"subscription\":\"none\",\"jid\":\"alice_add_contact_and_invite_2995@localhost\"}]">>,
213,32004}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
body => <<>>,method => <<"GET">>,role => client,
creds =>
{<<"bob_add_contact_and_invite_2995@localhost">>,
<<"makrolika">>},
return_headers => true}
*** User 2024-04-25 14:46:47.811 ***🔗
alice_add_contact_and_invite_2995@localhost/res1 out
<iq type='set' id='35383d2af9d9a6776ffb7430e19b9d50'>
<query xmlns='jabber:iq:roster'>
<item jid='bob_add_contact_and_invite_2995@localhost' name='Bob'/>
</query>
</iq>
*** User 2024-04-25 14:46:47.813 ***🔗
alice_add_contact_and_invite_2995@localhost/res1 in
<iq from='alice_add_contact_and_invite_2995@localhost' to='alice_add_contact_and_invite_2995@localhost/res1' id='push8122c62f3e00c6bd' type='set'>
<query xmlns='jabber:iq:roster'>
<item name='Bob' jid='bob_add_contact_and_invite_2995@localhost' subscription='none'/>
</query>
</iq>
*** User 2024-04-25 14:46:47.813 ***🔗
alice_add_contact_and_invite_2995@localhost/res1 out
<iq to='alice_add_contact_and_invite_2995@localhost' id='push8122c62f3e00c6bd' type='result'/>
*** User 2024-04-25 14:46:47.813 ***🔗
alice_add_contact_and_invite_2995@localhost/res1 in
<iq from='alice_add_contact_and_invite_2995@localhost' to='alice_add_contact_and_invite_2995@localhost/res1' id='35383d2af9d9a6776ffb7430e19b9d50' type='result'/>
*** User 2024-04-25 14:46:47.813 ***🔗
alice_add_contact_and_invite_2995@localhost/res1 out
<presence type='subscribed' to='bob_add_contact_and_invite_2995@localhost'/>
*** User 2024-04-25 14:46:47.817 ***🔗
bob_add_contact_and_invite_2995@localhost/res1 in
<iq from='bob_add_contact_and_invite_2995@localhost' to='bob_add_contact_and_invite_2995@localhost/res1' id='push7b03e8c399f74285' type='set'>
<query xmlns='jabber:iq:roster'>
<item jid='alice_add_contact_and_invite_2995@localhost' subscription='to'/>
</query>
</iq>
*** User 2024-04-25 14:46:47.817 ***🔗
Push3 {xmlel,<<"iq">>,
[{<<"from">>,<<"bob_add_contact_and_invite_2995@localhost">>},
{<<"to">>,<<"bob_add_contact_and_invite_2995@localhost/res1">>},
{<<"id">>,<<"push7b03e8c399f74285">>},
{<<"type">>,<<"set">>}],
[{xmlel,<<"query">>,
[{<<"xmlns">>,<<"jabber:iq:roster">>}],
[{xmlel,<<"item">>,
[{<<"jid">>,
<<"alice_add_contact_and_invite_2995@localhost">>},
{<<"subscription">>,<<"to">>}],
[]}]}]}
*** User 2024-04-25 14:46:47.824 ***🔗
REST request:
Code: 200
Req: {<0.82893.0>,<<"/api/contacts">>,<<"GET">>,
[{<<"Content-Type">>,<<"application/json">>},
{<<"Request-Id">>,<<"97075ae44b736b5c">>},
{<<"authorization">>,
<<"Basic Ym9iX2FkZF9jb250YWN0X2FuZF9pbnZpdGVfMjk5NUBsb2NhbGhvc3Q6bWFrcm9saWth">>}],
<<>>}
Result: {{<<"200">>,<<"OK">>},
[{<<"server">>,<<"Cowboy">>},
{<<"date">>,<<"Thu, 25 Apr 2024 14:46:47 GMT">>},
{<<"content-type">>,<<"application/json">>},
{<<"content-length">>,<<"88">>}],
<<"[{\"ask\":\"none\",\"subscription\":\"to\",\"jid\":\"alice_add_contact_and_invite_2995@localhost\"}]">>,
212,2539}
Params: #{path => <<"/api/contacts">>,
server => #{node => mongooseim@localhost},
body => <<>>,method => <<"GET">>,role => client,
creds =>
{<<"bob_add_contact_and_invite_2995@localhost">>,
<<"makrolika">>},
return_headers => true}
*** User 2024-04-25 14:46:47.824 ***🔗
bob_add_contact_and_invite_2995@localhost/res1 out
</stream:stream>
*** User 2024-04-25 14:46:47.824 ***🔗
bob_add_contact_and_invite_2995@localhost/res1 in
</stream:stream>
*** User 2024-04-25 14:46:47.824 ***🔗
alice_add_contact_and_invite_2995@localhost/res1 out
</stream:stream>
*** User 2024-04-25 14:46:47.825 ***🔗
alice_add_contact_and_invite_2995@localhost/res1 in
</stream:stream>
=== Ended at 2024-04-25 14:46:47
=== successfully completed test case
=== === Returned value: ok