ApiAccesses API

create new entry

POST /api/rest/admin/api-accesses

Parameters

Name Description
data[type] Resource type (api-accesses)
data[attributes][customer-id] Customer id
data[attributes][login] Login
data[attributes][password] Password
data[attributes][account-ids] Account ids
data[attributes][allowed-ips] Allowed ips

Request

Headers

Version: HTTP/1.0
Accept: application/vnd.api+json
Content-Type: application/vnd.api+json
Authorization: eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOjI3LCJhdWQiOlsiYWRtaW4iXSwiZXhwIjoxNzQwODUzMDIzfQ.HV5jNjLDiQRFMAdhtwYFAisXE0tEq7jUhnAVcvV-4aE
Host: example.org
Cookie: 

Route

POST /api/rest/admin/api-accesses

Body

{"data":{"type":"api-accesses","attributes":{"customer-id":10,"login":"login","password":"111111","account-ids":[26],"allowed-ips":["127.0.0.1","127.0.0.2"]}}}

Response

Headers

X-Frame-Options: SAMEORIGIN
X-XSS-Protection: 0
X-Content-Type-Options: nosniff
X-Permitted-Cross-Domain-Policies: none
Referrer-Policy: strict-origin-when-cross-origin
Content-Type: application/vnd.api+json
Vary: Accept
ETag: W/"ce4705bf5691d93dd42ae493518e3f6d"
Cache-Control: max-age=0, private, must-revalidate
X-Request-Id: 2fb749d3-3a47-4c15-af9a-b5ec55778cb4
X-Runtime: 0.025707
Content-Length: 247

Status

201 Created

Body

{
  "data": {
    "id": "4",
    "type": "api-accesses",
    "links": {
      "self": "http://example.org/api/rest/admin/api-accesses/4"
    },
    "attributes": {
      "customer-id": 10,
      "login": "login",
      "account-ids": [
        26
      ],
      "allowed-ips": [
        "127.0.0.1",
        "127.0.0.2"
      ],
      "allow-listen-recording": false
    }
  }
}