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.eyJleHAiOjE3MzE1Nzg3NDcsInN1YiI6MjJ9.HV7qn4vYShcIwtty7UxvggV9K050x0f2hLg7E7fbfaA
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-Download-Options: noopen
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: be341428-a965-48f7-80e9-270e8ad9e2a4
X-Runtime: 0.020930
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
    }
  }
}