Create config
The purpose of this API endpoint is to create create a new config entry. Each config item has a unique key and is associated with a user.
It is nothing more than a key-value system stored in the database, where the value is JSON-type content.
The application uses the settings associated with the user at various stages of its operation.
Requirements
Datasheet
-
Interactive API and documentation
http://localhost/docs#/Configs/create_config_api_v1_configs__post
-
Endpoint URL
POST
http://localhost/api/v1/configs -
URL parameters
None -
Body content
application/json -
Requires authentication
Yes -
Data to be returned
application/json
Steps
Create new config entry
-
Open the configs endpoint and choose
Create Configand to try it out
-
Run the command

-
The result will be something like

- Execute:
curl -X 'POST' \ 'http://localhost/api/v1/configs/' \ -H 'accept: application/json' \ -H 'Authorization: Bearer ACCESS_TOKEN' \ -H 'Content-Type: application/json' \ -d '{ "label": "Gupshup whatsapp with Tiledesk handson to human operator", "key": "tiledesk-ckm86efhr000i0aqyhrpuqj6v", "value": { "active": true, "channel": { "app": "superchatgupshupapi", "uid": "9XXXXXXXXXX4", "user": "", "password": "", "extra": {}, "apikey": "6XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX2", "module": "app.lib.channels.gupshupwhatsapp", "plugin": "gupshupwhatsapp", "channel": "whatsapp", "plugins": { "in": [ { "id": "optin_telegram", "extra": { "signup_url": "https://web.telegram.org" }, "order": 0, "module": "app.lib.channels.plugins.in.optin_telegram", "execute": "once", "description": "Optin for Telegram channel" } ], "out": [], "contact": { "extra": {}, "default": { "id": "ckkoibtlh000072xu98aqqm1r", "extra": {}, "module": "app.lib.channels.plugins.contacts.default", "description": "Get minimal contact info" } } } }, "handson": { "url": "https://api.tiledesk.com", "module": "app.lib.handson.tiledesk", "plugin": "tiledesk", "channel": "tiledesk", "project_id": "6XXXXXXXXXXXXXXXXXXXXXXX8", "allow_newchat": false, "shared_secret": "21eXXXXX-XXXX-XXXX-XXXX-fXXXXXXXXXXX0" }, "speech_name": "Empresa de demonstração", "speech_name_genre": "a" }, "status": 1 }'
- Expected outcome:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56
{ "label": "Gupshup whatsapp with Tiledesk handson to human operator", "key": "tiledesk-ckm86efhr000i0aqyhrpuqj6v", "value": { "active": true, "channel": { "app": "superchatgupshupapi", "uid": "9XXXXXXXXXX4", "user": "", "extra": {}, "apikey": "6XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX2", "module": "app.lib.channels.gupshupwhatsapp", "plugin": "gupshupwhatsapp", "channel": "whatsapp", "plugins": { "in": [ { "id": "optin_telegram", "extra": { "signup_url": "https://web.telegram.org" }, "order": 0, "module": "app.lib.channels.plugins.in.optin_telegram", "execute": "once", "description": "Optin for Telegram channel" } ], "out": [], "contact": { "extra": {}, "default": { "id": "ckkoibtlh000072xu98aqqm1r", "extra": {}, "module": "app.lib.channels.plugins.contacts.default", "description": "Get minimal contact info" } } }, "password": "" }, "handson": { "url": "https://api.tiledesk.com", "module": "app.lib.handson.tiledesk", "plugin": "tiledesk", "channel": "tiledesk", "project_id": "6XXXXXXXXXXXXXXXXXXXXXXX8", "allow_newchat": false, "shared_secret": "21eXXXXX-XXXX-XXXX-XXXX-fXXXXXXXXXXX0" }, "speech_name": "Empresa de demonstração", "speech_name_genre": "a" }, "status": 1, "id": "ckn7x37n000081xoj3317xau1", "owner_id": "cklv8qzo1000r0cs1q0klt1vb" }