Login to an conversation


You can login to any agent for an account, into a specific conversation inside a specific inbox.

Accessing the account directly from this API endpoint is mostly meant for your end user clients to do. you can login with the credentials you created for them bypassing the username/password and 2FA of accessing the online account directly. this is SSO login.

Moreover, you can build this solution over iFrame inside your own platform to allow accessing the system directly from your app.


Important Remarks

  • After creating login link, you must access it within 5 minutes and you can only access it once. if you need to access the same URL again, you must create a new link.

  • The URL you will get can be opened directly from your browser or from iFrame solution or implement it into your own application.

  • using this endpoint will not only open the account, it will take you to the specific conversation with the end user.


Settings:

URL

https://partners.99digital.co.il/api/online/loginConversation

Method

JSON via POST

Header

Authorization: Bearer {{access_token}}

*The access_token can be received from settings->get access token API.


Body:

Parameter

Description / Example

accountID

The account ID you wish to login to

agentID

The agent ID you wish to login to

server

The server subdomain hosting the account

inbox_id

The inbox ID to open. either this or conversation_id mandatory.

conversation_id

The conversation ID to open. either this or inbox_id is mandatory. if inbox_id is provided along with conversation_id, the inbox_id will be ignored.

phone_number

The phone number of the contact to open the conversation window. Either this or email is mandatory.

email

The email of the contact. Either this or phone_number is mandatory.

name

The name of the contact. not mandatory.


Response:

{
"status": "OK",
"accountID": 4142,
"agentID": 3142,
"server": "online",
"inbox_id", 12,
"conversation_id": 165,
"login": "https://online..."
}


Response-Explain:

Parameter

Description

status

OK or FAIL

"OK" means the request was successful.

"Fail" means error.

accountID

The account ID you login to

agentID

The agent ID you login to

server

The server subdomain you login to

inbox_id

The inbox_id provided

conversation_id

The conversation_id provided

login

The login URL for that account

reason

'reason' is the status explanation in case of FAIL


reason

explanation

1

not FAIL. the status is OK

2

Wrong credentials

3

Access token does not exist or expired, please generate another one from Settings - Get access token API

13

you need to use POST method.

29

accountID is invalid or wrong

32

You cant connect to a suspended account

34

server is invalid or wrong

35

agentID is invalid or wrong

36

inbox_id or conversation_id is invalid or wrong

37

phone_number or email is invalid or wrong