Agent

Get All Agents

GET https://widget.blinger.io/api/external/v1/agents

This endpoint allows you to get free cakes.

Headers

NameTypeDescription

Authorization

string

Authorization token.

{
    "status": 200,
    "data": [
        {
            "id": "5475272c-3bc0-40e9-83c4-0a1cd50bc721",
            "serviceUserId": "12345",
            "name": "Vadim Belorusov",
            "status": "online",
            "avatar": {
                "id": "856a906b-b55e-493a-b04c-df019fff6c8f",
                "type": "image",
                "meta": {
                    "width": 400,
                    "height": 400
                },
                "info": {
                    "ext": "jpeg",
                    "name": "5d1dbd5e921f6",
                    "path": "/91/44/41/96b85c57f9ae26a2376154c82dd55b9f6cb33ea2b038db8057b8db04a559c7f0.jpeg",
                    "size": 5106,
                    "mimeType": "image/jpeg"
                },
                "url": {
                    "120x120": "http://static.widget.blinger.io/120x120/91/44/41/96b85c57f9ae26a2376154c82dd55b9f6cb33ea2b038db8057b8db04a559c7f0.jpeg",
                    "520x400": "http://static.widget.blinger.io/520x400/91/44/41/96b85c57f9ae26a2376154c82dd55b9f6cb33ea2b038db8057b8db04a559c7f0.jpeg",
                    "default": "http://static.widget.blinger.io/91/44/41/96b85c57f9ae26a2376154c82dd55b9f6cb33ea2b038db8057b8db04a559c7f0.jpeg"
                },
                "createdAt": 1562198400,
                "updatedAt": 1562198400
            },
            "active": true,
            "createdAt": 1562230110,
            "updatedAt": 1562230110
        },
        {
            "id": "c671d030-584e-4422-8710-9215c04b6a64",
            "serviceUserId": "123456",
            "name": "Vadim Belorusov",
            "status": "online",
            "avatar": {
                "id": "76d94b6b-a45c-4d62-8010-bd2f52d8c846",
                "type": "image",
                "meta": {
                    "width": 400,
                    "height": 400
                },
                "info": {
                    "ext": "jpeg",
                    "name": "5d1db8373db3a",
                    "path": "/c2/b1/62/be16b35869e9491a6761c013cbae7548f23b17abb225eaa82efd214264779825.jpeg",
                    "size": 5106,
                    "mimeType": "image/jpeg"
                },
                "url": {
                    "120x120": "http://static.widget.blinger.io/120x120/c2/b1/62/be16b35869e9491a6761c013cbae7548f23b17abb225eaa82efd214264779825.jpeg",
                    "520x400": "http://static.widget.blinger.io/520x400/c2/b1/62/be16b35869e9491a6761c013cbae7548f23b17abb225eaa82efd214264779825.jpeg",
                    "default": "http://static.widget.blinger.io/c2/b1/62/be16b35869e9491a6761c013cbae7548f23b17abb225eaa82efd214264779825.jpeg"
                },
                "createdAt": 1562198400,
                "updatedAt": 1562198400
            },
            "active": true,
            "createdAt": 1562228791,
            "updatedAt": 1562228791
        }
    ]
}

Get Agent

GET https://widget.blinger.io/api/external/v1/agents/:id

Path Parameters

NameTypeDescription

id

string

ID of the agent.

Headers

NameTypeDescription

Authorization

string

Authorization token.

{
    "status": 200,
    "data": {
        "id": "5475272c-3bc0-40e9-83c4-0a1cd50bc721",
        "serviceUserId": "12345",
        "name": "Vadim Belorusov",
        "status": "online",
        "avatar": {
            "id": "856a906b-b55e-493a-b04c-df019fff6c8f",
            "type": "image",
            "meta": {
                "width": 400,
                "height": 400
            },
            "info": {
                "ext": "jpeg",
                "name": "5d1dbd5e921f6",
                "path": "/91/44/41/96b85c57f9ae26a2376154c82dd55b9f6cb33ea2b038db8057b8db04a559c7f0.jpeg",
                "size": 5106,
                "mimeType": "image/jpeg"
            },
            "url": {
                "120x120": "http://static.widget.blinger.io/120x120/91/44/41/96b85c57f9ae26a2376154c82dd55b9f6cb33ea2b038db8057b8db04a559c7f0.jpeg",
                "520x400": "http://static.widget.blinger.io/520x400/91/44/41/96b85c57f9ae26a2376154c82dd55b9f6cb33ea2b038db8057b8db04a559c7f0.jpeg",
                "default": "http://static.widget.blinger.io/91/44/41/96b85c57f9ae26a2376154c82dd55b9f6cb33ea2b038db8057b8db04a559c7f0.jpeg"
            },
            "createdAt": 1562198400,
            "updatedAt": 1562198400
        },
        "active": true,
        "createdAt": 1562230110,
        "updatedAt": 1562230110
    }
}

Create Agent

POST https://widget.blinger.io/api/external/v1/agents

Headers

NameTypeDescription

Authorization

string

Authorization token.

Request Body

NameTypeDescription

active

boolean

Is agent active or not.

serviceUserId

string

Simple string identificates your service.

name

string

Agent's Name.

avatar

string

Url of the Agent's Avatar.

status

string

Status of the agent. Possible values: offline or online.

{
    "status": 200,
    "data": {
        "id": "c2e53dee-ad8d-45dc-909a-465746932f11",
        "serviceUserId": "12345",
        "name": "Vadim Belorusov",
        "status": "online",
        "avatar": {
            "id": "366baf52-920e-4483-96b1-36955d49f65f",
            "type": "image",
            "meta": {
                "width": 400,
                "height": 400
            },
            "info": {
                "name": "5d1df34c0a573",
                "ext": "jpeg",
                "mimeType": "image/jpeg",
                "size": 5106,
                "path": "/1c/a8/7a/405bb573328256eebf41c6c99fc1c445271acb9a594bb91fddabc963d1e6ba70.jpeg"
            },
            "url": {
                "120x120": "http://static.widget.blinger.io/120x120/1c/a8/7a/405bb573328256eebf41c6c99fc1c445271acb9a594bb91fddabc963d1e6ba70.jpeg",
                "520x400": "http://static.widget.blinger.io/520x400/1c/a8/7a/405bb573328256eebf41c6c99fc1c445271acb9a594bb91fddabc963d1e6ba70.jpeg",
                "default": "http://static.widget.blinger.io/1c/a8/7a/405bb573328256eebf41c6c99fc1c445271acb9a594bb91fddabc963d1e6ba70.jpeg"
            },
            "createdAt": 1562243916,
            "updatedAt": 1562243916
        },
        "active": true,
        "createdAt": 1562243916,
        "updatedAt": 1562243916
    }
}

Update agent

PUT https://widget.blinger.io/api/external/v1/agents/:id

Path Parameters

NameTypeDescription

id

string

ID of the agent.

Headers

NameTypeDescription

Authorization

string

Authorization token.

Request Body

NameTypeDescription

active

boolean

Is agent active or not.

serviceUserId

string

Simple string identificates your service.

name

string

Agent's Name.

avatar

string

Url of the Agent's Avatar.

status

string

Status of the agent. Possible values: offline or online.

{
    "status": 200,
    "data": {
        "id": "c2e53dee-ad8d-45dc-909a-465746932f11",
        "serviceUserId": "12345",
        "name": "Vadim Belorusov",
        "status": "online",
        "avatar": {
            "id": "366baf52-920e-4483-96b1-36955d49f65f",
            "type": "image",
            "meta": {
                "width": 400,
                "height": 400
            },
            "info": {
                "name": "5d1df34c0a573",
                "ext": "jpeg",
                "mimeType": "image/jpeg",
                "size": 5106,
                "path": "/1c/a8/7a/405bb573328256eebf41c6c99fc1c445271acb9a594bb91fddabc963d1e6ba70.jpeg"
            },
            "url": {
                "120x120": "http://static.widget.blinger.io/120x120/1c/a8/7a/405bb573328256eebf41c6c99fc1c445271acb9a594bb91fddabc963d1e6ba70.jpeg",
                "520x400": "http://static.widget.blinger.io/520x400/1c/a8/7a/405bb573328256eebf41c6c99fc1c445271acb9a594bb91fddabc963d1e6ba70.jpeg",
                "default": "http://static.widget.blinger.io/1c/a8/7a/405bb573328256eebf41c6c99fc1c445271acb9a594bb91fddabc963d1e6ba70.jpeg"
            },
            "createdAt": 1562243916,
            "updatedAt": 1562243916
        },
        "active": true,
        "createdAt": 1562243916,
        "updatedAt": 1562243916
    }
}

Last updated