Skill Management API


Use the Skill Management REST API to enable and disable skills for Alexa Smart Properties (ASP) units, such as rooms.

API endpoint

Based on the country of your organization, set the Host parameter in the request header to one of the following API endpoints.

Country Endpoint

CA, US

https://api.amazonalexa.com

DE, ES, FR, IT, UK

https://api.eu.amazonalexa.com

JP

https://api.fe.amazonalexa.com

Authentication

Each API request must have an authorization header whose value is the access token retrieved from Login with Amazon (LWA). For details, see Manage API Access.

Operations

The Skill Management API includes the following operations.

Description HTTP method and path

Disable skill for unit

DELETE /v1/skills/{skillId}/enablements?unitId={unitId}&stage={stage}

Disable skill for multiple units

POST /v1/skills/{skillId}/enablements/batchDelete

Enable skill for unit

POST /v1/skills/{skillId}/enablements

Enable skill for multiple units

POST /v1/skills/{skillId}/enablements/batch

Get skill enablement for unit

GET /v1/skills/{skillId}/enablements?unitId={unitId}&stage={stage}&expand={expand}

Get skill enablement for multiple units

POST /v1/skills/enablements/batchGet

List enabled skills for unit

GET /v1/skills/enablements?unitId={unitId}&expand={expand}&maxResults={maxResults}&nextToken={nextToken}

Disable skill for unit

Disable a skill for the specified unit.

This operation is available in the following countries.

Healthcare Hospitality Senior Living Core

US

US, UK, FR, CA, IT, DE, ES, JP

US, UK, FR, CA, IT, DE, ES, JP

US

Request

To disable a skill, you make a DELETE request to the /v1/skills/{skillId}/enablements resource.

Request path and header example

Copied to clipboard.

DELETE /v1/skills/{skillId}/enablements?unitId={unitId}&stage={stage} HTTP/1.1
Host: api.amazonalexa.com
Accept: application/json
Authorization: Bearer {access token}

Request path and header parameters

Parameter Located in Description Type Required

skillId

Path

Identifies the skill.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.skill.did.{id}.
Valid values: 1 – 255 characters.

String

Yes

unitId

Query

Filter on the specified unit.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.unit.did.{id}.

String

Yes

stage

Query

Filter on the skill stage.
Valid values: live, development.

String

No

access token

Header

Access token for the customer.
Set to an LWA token.

String

Yes

Request body example

The request has no body.

Request body properties

The request has no body.

Response

A successful response returns HTTP 204 No Content. On error, the response returns the appropriate HTTP status code and includes a response body with an Error object.

Response body example

The response has no body.

Response body properties

The response has no body.

HTTP status codes

Status Description

204 No Content

Skill disabled on the specified unit successfully.

400 Bad Request

Indicates that one or more properties in the request body aren't valid.

401 Unauthorized

Request didn't include the authorization token, or the included token expired or isn't valid. Or, you don't have access to the resource.

403 Forbidden

Indicates that the authorization token is valid, but the requested operation isn't allowed.

404 Not Found

Requested resource not found.

429 Too Many Requests

Permitted rate limit, specified as the number of requests per unit of time, exceeded. You can retry the request by using exponential back-off.

500 Server Error

Error occurred on the server. You can retry the request by using exponential back-off.

503 Service Unavailable

Server is down for maintenance, overloaded, or otherwise unavailable to handle the incoming request.

Disable skill for multiple units

Disable the specified skill for a list of units.

This operation is available in the following countries.

Healthcare Hospitality Senior Living Core

US

US, UK, FR, CA, IT, DE, ES, JP

US, UK, FR, CA, IT, DE, ES, JP

US

Request

To disable a skill for multiple units, you make a POST request to the /v1/skills/{skillId}/enablements/batchDelete resource.

Request path and header example

Copied to clipboard.

POST /v1/skills/{skillId}/enablements/batchDelete HTTP/1.1
Host: api.amazonalexa.com
Accept: application/json
Authorization: Bearer {access token}

Request path and header parameters

Parameter Located in Description Type Required

skillId

Path

Identifies the skill.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.skill.did.{id}.
Valid values: 1 – 255 characters.

String

Yes

access token

Header

Access token for the customer.
Set to an LWA token.

String

Yes

Request body example

Copied to clipboard.

{
    "items": [{
            "itemId": 0,
            "unitId": "amzn1.alexa.unit.101",
            "stage": "live"
        },
        {
            "itemId": 1,
            "unitId": "amzn1.alexa.unit.102",
            "stage": "development"
        },
        {
            "itemId": 2,
            "unitId": "amzn1.alexa.unit.103"
        }
    ]
}

Request body properties

Property Description Type Required

items

List of units on which to disable the specified skill.
You can include up to 100 units in the list.

Array of objects

Yes

items[].itemId

Unique identifier for the disablement.

Integer

Yes

items[].unitId

Identifies the unit.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.unit.did.{id}.

String

Yes

items[].stage

Identifies the skill stage.
Valid values: live, development.

String

No

Response

A successful response returns HTTP 202 Accepted. On error, the response returns the appropriate HTTP status code and includes a response body with a BatchError object.

Response body example

The response has no body.

Response body properties

The response has no body.

HTTP status codes

Status Description

202 Accepted

Skill disabled successfully.

400 Bad Request

Indicates that one or more properties in the request body aren't valid.

The response might include one of the following errors types and messages:

  • BAD_REQUEST – The request is malformed or is missing any required parameters.
  • INVALID_PARAM – The request has a missing or invalid parameter.

401 Unauthorized

Request didn't include the authorization token, or the included token expired or isn't valid. Or, you don't have access to the resource.

403 Forbidden

Indicates that the authorization token is valid, but the requested operation isn't allowed.

404 Not Found

Requested resource not found.

The response might include one of the following errors types and messages:

  • ENABLEMENT_NOT_FOUND – The requested enablement not found.
  • SKILL_STAGE_NOT_FOUND – The requested skill ID and stage combination not found.

429 Too Many Requests

Permitted rate limit, specified as the number of requests per unit of time, exceeded. You can retry the request by using exponential back-off.

500 Server Error

Error occurred on the server. You can retry the request by using exponential back-off.
Sometimes this error occurs when retrieving name-free invocation status fails.

503 Service Unavailable

Server is down for maintenance, overloaded, or otherwise unavailable to handle the incoming request.

Enable skill for unit

Enable the skill on the specified unit. You can provide partition, name-free interaction, and account linking information. If you include account linking information, Alexa attempts to link the accounts.

This operation is available in the following countries.

Healthcare Hospitality Senior Living Core

US

US, UK, FR, CA, IT, DE, ES, JP

US, UK, FR, CA, IT, DE, ES, JP

US

Request

To enable a skill, you make a POST request to the /v1/skills/{skillId}/enablements resource.

Request path and header example

Copied to clipboard.

POST /v1/skills/{skillId}/enablements HTTP/1.1
Host: api.amazonalexa.com
Accept: application/json
Authorization: Bearer {access token}

Request path and header parameters

Parameter Located in Description Type Required

skillId

Path

Identifies the skill.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.skill.did.{id}.
Valid values: 1 – 255 characters.

String

Yes

access token

Header

Access token for the customer.
Set to an LWA token.

String

Yes

Request body examples

The following example shows a basic skill enablement on a unit without additional details, such as account linking or name-free interaction.

The following example shows a skill enablement on a unit with account linking and partition information.

The following example shows a skill enablement for a skill that supports name-free interaction.

Request body properties

Property Description Type Required

unitId

Identifies the unit.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.unit.did.{id}.

String

Yes

stage

Identifies the skill stage.
Valid values: live, development.

String

Yes

partitionName

Identifies a logical grouping of resources, such as devices, endpoints, or skills. Contains either a single partition name or a comma-separated list of partition names. A partition name is a single nonempty string that can contain alphanumeric characters and hyphens but not whitespace.
For example, "Room-101" and "Room101, Room202" are valid values for this parameter. However, the following values aren't valid: "" (empty list), "Room101, ,Room202" (not properly comma-separated), "Room 101" (contains whitespace).

String

No

accountLinkRequest

Account linking information.
Required for skills that require account linking.

Object

No

accountLinkRequest.redirectUri

Use the same value as the redirect_uri parameter included in the authorization request to your OAuth 2.0 server to obtain the user's authorization code. This URI enables Amazon to retrieve access tokens from your token server. This URL must be opaque to Amazon.

String

Yes

accountLinkRequest.authCode

OAuth 2.0 authorization code. For details, see Authorization code grant flow.

String

Yes

accountLinkRequest.type

Type of account linking request based on OAuth 2.0 authorization request protocols.
Valid value: AUTH_CODE.

String

Yes

nameFreeInvocationRequest

Name-free interaction information.
Include for skills that support name-free interaction only.

Object

No

nameFreeInvocationRequest.locales

Locales to enable for name-free interaction. The skill must have an interaction model that supports the locales. Include up to five locales.
Valid values: en-US, es-US,en-CA,fr-CA,en-GB,fr-FR,it-IT,de-DE,es-ES.

Array of strings

Yes

Response

A successful response returns HTTP 201 Created, along with the enablement details for the specified unit. On error, the response returns the appropriate HTTP status code and includes a response body with an Error object.

Response body example

{
  "skill": {
    "stage": "stage",
    "id": "{skillId}"
  },
  "unit": {
    "id": "{unitId}"
  },
  "accountLink": {
    "status": "LINKED"
  },
  "nameFreeInvocation": {
    "status": "ENABLED",
    "locales": ["en-US"]
  },
  "status": "ENABLING",
}

Response body properties

Property Description Type

skill

Skill information.

Object

skill.id

Identifies the skill.

String

skill.stage

Indicates stage of the skill.
Valid values: development, live.

String

unit

Identifies the unit.

Object

unit.id

ID of the unit.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.unit.did.{id}.

String

accountLink

Status of account linking between the your Amazon business account and the your account in your system. Included for skills that require account linking.

Object

accountLink.status

Accounting linking status. Set to NOT_LINKED for skills that don't support account linking.
Valid values: LINKED, NOT_LINKED.

String

nameFreeInvocation

Name-free interaction information.

Object

nameFreeInvocation.status

Name-free interaction enablement status. Set to DISABLED for skills that don't support name free interaction.
Valid values: DISABLED, ENABLED.

String

nameFreeInvocation.locales

(Optional) Locales to enable for name-free interaction. The skill must have an interaction model that supports the locales. Include up to five locales.
Valid values: en-US, es-US,en-CA,fr-CA,en-GB,fr-FR,it-IT,de-DE,es-ES.

Array of strings

status

Enablement status of the skill.
Valid values:

  • ENABLED: Skill was successfully enabled.
  • ENABLING: Enablement was initiated.

String

HTTP status codes

Status Description

201 Created

Response body contains the enablement results.

400 Bad Request

Indicates that one or more properties in the request body aren't valid.
The following example shows the response body with the error code and message.

{
     "message": "The property is outside the allowed range.",
     "code": "INVALID_STRING_LENGTH"
}

401 Unauthorized

Request didn't include the authorization token, or the included token expired or isn't valid. Or, you don't have access to the resource.

403 Forbidden

Indicates that the authorization token is valid, but the requested operation isn't allowed.

404 Not Found

Requested resource not found.

429 Too Many Requests

Permitted rate limit, specified as number of requests per unit of time, exceeded. Retry the request by using exponential back-off.

500 Server Error

Error occurred on the server. Retry the request by using exponential back-off.

503 Service Unavailable

Server is down for maintenance, overloaded, or otherwise unavailable to handle the incoming request.

Enable skill for multiple units

Enable a skill for multiple units in a single request. You can provide partition, name-free interaction, and account linking information. If you include account linking information, Alexa attempts to link the accounts.

This operation is available in the following countries.

Healthcare Hospitality Senior Living Core

US

US, CA, IT, DE, ES, JP

US, UK, FR, CA, IT, DE, ES, JP

US

Request

To enable a skill on multiple units, you make a POST request to the XYZ resource.

Request path and header example

Copied to clipboard.

POST /v1/skills/{skillId}/enablements/batch HTTP/1.1
Host: api.amazonalexa.com
Accept: application/json
Authorization: Bearer {access token}

Request path and header parameters

Parameter Located in Description Type Required

skillId

Path

Identifies the skill.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.skill.did.{id}.
Valid values: 1 – 255 characters.

String

Yes

access token

Header

Access token for the customer.
Set to an LWA token.

String

Yes

Request body examples

The following example shows a basic skill enablement on multiple units without additional details, such as account linking or name-free interaction.

The following example shows a skill enablement on multiple units with account linking and partition information.

The following example shows a skill enablement for a skill that supports name-free interaction.

Request body properties

Property Description Type Required

items

List of units on which to enable the specified skill.
You can include up to 100 units in the list.

Array of objects

Yes

items[].itemId

Unique identifier for the enablement.

Integer

Yes

items[].unitId

Identifies the unit.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.unit.did.{id}.

String

Yes

items[].stage

Identifies the skill stage.
Valid values: live, development.

String

No

items[].partitionName

Identifies a logical grouping of resources, such as devices, endpoints, or skills. Contains either a single partition name or a comma-separated list of partition names. A partition name is a single nonempty string that can contain alphanumeric characters and hyphens but not whitespace.
For example, "Room-101" and "Room101, Room202" are valid values for this parameter. However, the following values aren't valid: "" (empty list), "Room101, ,Room202" (not properly comma-separated), "Room 101" (contains whitespace).

String

No

items[].accountLinkRequest

Account linking information.
Required for skills that require account linking.

Object

No

items[].accountLinkRequest.redirectUri

Use the same value as the redirect_uri parameter included in the authorization request to your OAuth 2.0 server to obtain the user's authorization code. This URI enables Amazon to retrieve access tokens from your token server. This URL must be opaque to Amazon.

String

Yes

items[].accountLinkRequest.authCode

OAuth 2.0 authorization code. For details, see Authorization code grant flow.

String

Yes

items[].accountLinkRequest.type

Type of account linking request based on OAuth 2.0 authorization request protocols.
Valid value: AUTH_CODE.

String

Yes

items[].nameFreeInvocationRequest

Name-free interaction information.
Include for skills that support name-free interaction only.

Object

No

items[].nameFreeInvocationRequest.locales

Locales to enable for name-free interaction. The skill must have an interaction model that supports the locales. Include up to five locales.
Valid values: en-US, es-US,en-CA,fr-CA,en-GB,fr-FR,it-IT,de-DE,es-ES.

Array of strings

Yes

Response

A successful response returns HTTP 202 Accepted. On error, the response returns the appropriate HTTP status code and includes a response body with a BatchError object.

Response body examples

The response has no body.

Response body properties

The response has no body.

HTTP status codes

Status Description

202 Accepted

Skill enabled on each unit successfully.

400 Bad Request

Indicates that one or more properties in the request body aren't valid.

The response might include one of the following errors types and messages:

  • BAD_REQUEST – The request is malformed or is missing any required parameters.
  • INVALID_PARAM – The request has a missing or invalid parameter.

401 Unauthorized

Request didn't include the authorization token, or the included token expired or isn't valid. Or, you don't have access to the resource.

403 Forbidden

Indicates that the authorization token is valid, but the requested operation isn't allowed.

404 Not Found

Requested resource not found.

The response might include one of the following errors types and messages:

  • ENABLEMENT_NOT_FOUND – The requested enablement not found.
  • SKILL_STAGE_NOT_FOUND – The requested skill ID and stage combination not found.

429 Too Many Requests

Permitted rate limit, specified as the number of requests per unit of time, exceeded. You can retry the request by using exponential back-off.

500 Server Error

Error occurred on the server. You can retry the request by using exponential back-off.
Sometimes this error occurs when retrieving name-free invocation status fails.

503 Service Unavailable

Server is down for maintenance, overloaded, or otherwise unavailable to handle the incoming request.

Get skill enablement for unit

Get the skill enablement record for a specific skill and unit.

This operation is available in the following countries.

Healthcare Hospitality Senior Living Core

US

US, UK, FR, CA, IT, DE, ES, JP

US, UK, FR, CA, IT, DE, ES, JP

US

Request

To get enablement record, you make a GET request to the /v1/skills/{skillId}/enablements resource.

Request path and header example

Copied to clipboard.

GET /v1/skills/{skillId}/enablements?unitId={unitId}&stage={stage}&expand={expand} HTTP/1.1
Host: api.amazonalexa.com 
Accept: application/json
Authorization: Bearer {access token}

Request path and header parameters

Parameter Located in Description Type Required

skillId

Path

Identifies the skill.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.skill.did.{id}.
Valid values: 1 – 255 characters.

String

Yes

unitId

Query

Filter on the specified unit.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.unit.did.{id}.

String

Yes

stage

Query

Filter on the skill stage.
Valid values: live, development.

String

No

expand

Query

Identify an attribute or set of attributes to include in the response.
Valid value: nameFreeInvocation.

String

No

access token

Header

Access token for the customer.
Set to an LWA token.

String

Yes

Request body example

The request has no body.

Request body properties

The request has no body.

Response

A successful response returns HTTP 200 OK, along with enablement details for the specified skill and unit. On error, the response returns the appropriate HTTP status code and includes a response body with an Error object.

Response body examples

The following example shows skill enablement details for the specified skill and unit.

The following example shows skill enablement details for the specified skill and unit, for a request with the expand attribute.

Response body properties

Property Description Type

skill

Skill information.

Object

skill.id

Identifies the skill.

String

skill.stage

Indicates stage of the skill.
Valid values: development, live.

String

unit

Identifies the unit.

Object

unit.id

ID of the unit.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.unit.did.{id}.

String

accountLink

Status of account linking between the your Amazon business account and the your account in your system.

Object

accountLink.status

Accounting linking status.
Set to NOT_LINKED for skills that don't support account linking.
Valid values: LINKED, NOT_LINKED.

String

nameFreeInvocation

Name-free interaction information.

Object

nameFreeInvocation.status

Name-free interaction enablement status. Set to DISABLED for skills that don't support name-free interaction.
Valid values: DISABLED, ENABLED.

String

nameFreeInvocation.locales

(Optional) Locales to enable for name-free interaction. The skill must have an interaction model that supports the locales. Includes up to five locales for skills that support name-free invocation.
Valid values: en-US, es-US,en-CA,fr-CA,en-GB,fr-FR,it-IT,de-DE,es-ES.

Array of strings

status

Enablement status of the skill.
Valid values:

  • ENABLED: Skill was successfully enabled.
  • ENABLING: Enablement was initiated.

String

HTTP status codes

Status Description

200 OK

Response body contains enablement details for the specified skill and unit.

400 Bad Request

Indicates that one or more properties in the request body aren't valid.

401 Unauthorized

Request didn't include the authorization token, or the included token expired or isn't valid. Or, you don't have access to the resource.

403 Forbidden

Indicates that the authorization token is valid, but the requested operation isn't allowed.

404 Not Found

Requested resource not found.

429 Too Many Requests

Permitted rate limit, specified as the number of requests per unit of time, exceeded. You can retry the request by using exponential back-off.

500 Server Error

Error occurred on the server. You can retry the request by using exponential back-off.

503 Service Unavailable

Server is down for maintenance, overloaded, or otherwise unavailable to handle the incoming request.

Get skill enablement for multiple units

Get the skill enablement record for a specific skill and one or more specified units.

This operation is available in the following countries.

Healthcare Hospitality Senior Living Core

US

US, UK, FR, CA, IT, DE, ES, JP

US, UK, FR, CA, IT, DE, ES, JP

US

Request

To get enablements, you make a POST request to the /v1/skills/enablements/batchGet resource.

Request path and header example

Copied to clipboard.

GET /v1/skills/enablements/batchGet HTTP/1.1
Host: api.amazonalexa.com
Accept: application/json
Authorization: Bearer {access token}

Request path and header parameters

Parameter Located in Description Type Required

access token

Header

Access token for the customer.
Set to an LWA token.

String

Yes

Request body example

The following example requests skill enablement records for four units. The example request includes the expand parameter.

Copied to clipboard.

{
  "items": [
    {
      "itemId": 0,
      "unitId": "amzn1.alexa.unit.101"
    },
    {
      "itemId": 1,
      "unitId": "amzn1.alexa.unit.102"
    },
    {
      "itemId": 2,
      "unitId": "amzn1.alexa.unit.103"
    },
    {
      "itemId": 3,
      "unitId": "amzn1.alexa.unit.104"
    },
  ],
  "expand": ["nameFreeInvocation"],
  "paginationContext": {
      "maxResults" : 5,
      "nextToken": "someToken.1"
  }
}

Request body properties

Property Description Type Required

items

List of requested units.
You can include up to 100 units in the list.

Array of objects

Yes

items[].itemId

Unique identifier for the request.

Integer

Yes

items[].unitId

Identifies the unit.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.unit.did.{id}.

String

Yes

expand

Identify an attribute or set of attributes to include in the response.
Valid value: nameFreeInvocation.

String

No

paginationContext

Include to get the next set of results.
For details, see Handling Pagination in Query Results.

Object

No

paginationContext.maxResults

Maximum number of results to return in the response.
Valid values: 1–10. Default: 10.

Integer

No

paginationContext.nextToken

Include from the previous response.

String

No

Response

A successful response returns HTTP 200 OK, along with a list of enabled skills for the specified units. On error, the response returns the appropriate HTTP status code and includes a response body with a BatchError object.

Response body example

Response body properties

Property Description Type

results

List of enabled skills for the specified units.

Array of objects

results[].itemId

Identifies the item from the request.

Integer

results[].enablements

List of enabled skills for the unit.

Array of objects

results[].enablements[].skill

Skill information.

Object

results[].enablements[].skill.id

Identifies the skill.

String

results[].enablements[].skill.stage

Indicates stage of the skill.
Valid values: development, live.

String

results[].enablements[].unit

Identifies the unit.

Object

results[].enablements[].unit.id

ID of the unit.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.unit.did.{id}.

String

results[].enablements[].accountLink

Status of account linking between the your Amazon business account and the your account in your system.

Object

results[].enablements[].accountLink.status

Accounting linking status.
Set to NOT_LINKED for skills that don't require account linking.
Valid values: LINKED, NOT_LINKED.

String

results[].enablements[].nameFreeInvocation

Name-free interaction information.

Object

results[].enablements[].nameFreeInvocation.status

Name-free interaction enablement status. Set to DISABLED for skills that don't support name free interaction.
Valid values: DISABLED, ENABLED.

String

results[].enablements[].nameFreeInvocation.locales

(Optional) Locales to enable for name-free interaction. The skill must have an interaction model that supports the locales. Includes up to five locales.
Valid values: en-US, es-US,en-CA,fr-CA,en-GB,fr-FR,it-IT,de-DE,es-ES.

Array of strings

results[].enablements[].status

Enablement status of the skill.
Valid values:

  • ENABLED: Skill was successfully enabled.
  • ENABLING: Enablement was initiated.

String

paginationContext

Indicates whether there are more results to return.

Object

paginationContext.nextToken

Included when the response is truncated. Use this value in a subsequent request.
If not present, there are no more results.

String

HTTP status codes

Status Description

200 OK

Response body contains list of enablement status per specified unit.

400 Bad Request

Indicates that one or more properties in the request body aren't valid.

The response might include one of the following errors types and messages:

  • BAD_REQUEST – The request is malformed or is missing any required parameters.
  • INVALID_PARAM – The request has a missing or invalid parameter.

401 Unauthorized

Request didn't include the authorization token, or the included token expired or isn't valid. Or, you don't have access to the resource.

403 Forbidden

Indicates that the authorization token is valid, but the requested operation isn't allowed.

404 Not Found

Requested resource not found.

The response might include one of the following errors types and messages:

  • ENABLEMENT_NOT_FOUND – The requested enablement not found.
  • SKILL_STAGE_NOT_FOUND – The requested skill ID and stage combination not found.

429 Too Many Requests

Permitted rate limit, specified as the number of requests per unit of time, exceeded. You can retry the request by using exponential back-off.

500 Server Error

Error occurred on the server. You can retry the request by using exponential back-off.
Sometimes this error occurs when retrieving name-free invocation status fails.

503 Service Unavailable

Server is down for maintenance, overloaded, or otherwise unavailable to handle the incoming request.

List enabled skills for unit

List the enabled skills for the specified unit.

This operation is available in the following countries.

Healthcare Hospitality Senior Living Core

US

US, UK, FR, CA, IT, DE, ES, JP

US, UK, FR, CA, IT, DE, ES, JP

US

To list skills, you make a GET request to the /v1/skills/enablements resource.

Request path and header example

Copied to clipboard.

GET /v1/skills/enablements?unitId={unitId}&expand={expand}&maxResults={maxResults}&nextToken={nextToken} HTTP/1.1
Host: api.amazonalexa.com
Accept: application/json
Authorization: Bearer {access token}

Request path and header parameters

Parameter Located in Description Type Required

unitId

Query

Filter on the unit.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.unit.did.{id}.

String

Yes

expand

Query

Identify an attribute or set of attributes to include in the response.
Valid value: nameFreeInvocation.

String

No

maxResults

Query

Maximum number of results to return in the response.
Valid values: 1–10. Default: 10.

Integer

No

nextToken

Query

Token from the previous response.
Include if iterating over a paginated response.

String

No

access token

Header

Access token for the customer.
Set to an LWA token.

String

Yes

Request body example

The request has no body.

Request body properties

The request has no body.

Response

A successful response returns HTTP 200 OK, along with a list of skills enabled for the specified unit. On error, the response returns the appropriate HTTP status code and includes a response body with an Error object.

Response body example

The following example lists all enabled skills for the specified unit.

The following example lists all enabled skills for the specified unit for a request with the expand attribute.

Response body properties

Property Description Type

items

List of enabled skills for the specified unit.

Array of objects

items[].skill

Skill information.

Object

items[].skill.id

Identifies the skill.

String

items[].skill.stage

Indicates stage of the skill.
Valid values: development, live.

String

items[].unit

Unit to which the skill is associated.

Object

items[].unit.id

ID of the unit.
Formatted as Amazon Common Identifier (ACI), amzn1.alexa.unit.did.{id}.

String

items[].accountLink

Status of account linking between the your Amazon business account and the your account in your system.

Object

items[].accountLink.status

Accounting linking status.
Set to NOT_LINKED for skills that don't require account linking.
Valid values: LINKED, NOT_LINKED.

String

items[].status

Enablement status of the skill.
Valid values:

  • ENABLED: Skill was successfully enabled.
  • ENABLING: Enablement was initiated.

String

items[].nameFreeInvocation

(Optional) Name-free interaction information. Included in the response if you included the expand parameter in the request.

Object

items[].nameFreeInvocation.status

Name-free interaction enablement status. Set to DISABLED for skills that don't support name free interaction.
Valid values: DISABLED, ENABLED.

String

items[].nameFreeInvocation.locales

(Optional) Locales to enable for name-free interaction. The skill must have an interaction model that supports the locales. Includes up to five locales.
Valid values: en-US, es-US,en-CA,fr-CA,en-GB,fr-FR,it-IT,de-DE,es-ES.

Array of strings

paginationContext

Indicates whether there are more results to return.

Object

paginationContext.nextToken

Included when the response is truncated. Use this value in a subsequent request.
If no more results, nextToken isn't included.

String

Object definitions

The Skill Management API defines the following object definitions.

BatchError object

The BatchError object defines the error code and description included in the response when an error occurs during a batch operation. The itemId represents the item from the request that failed.

The following example shows the response body.

{
  "errors": [
    {
       "itemId": 0,
       "status": 400,   
       "errorCode" : "INVALID_PRINCIPAL_ID",   
       "errorDescription": "Invalid principalId specified."
    },
    {
       "itemId": 3,
       "status": 400,      
       "errorCode" : "REQUEST_LIMIT_EXCEEDED",
       "errorDescription": "The number of request items in the batch request exceeds the limit (50)."
    }
  ]
}

The BatchError object defines the following properties.

Property Description Type

itemId

(Optional) Identifies the request item that failed.

Integer

status

HTTP status code.

String

errorCode

Type of error that occurred.

String

errorDescription

Human-readable error message. The error message appears only for debugging/logging purposes. You must not share it with the customer. No business logic should depend on the content of the error message.

String

Error object

The Error object defines the error type and message included in the response when an error occurs.

The following example shows the response body.

{
    "type": "BAD_REQUEST",
    "message": "The request is malformed or is missing any required parameters."
}

The Error object defines the following properties.

Property Description Type

type

Type of error that occurred.
For specific error types, see the HTTP status code table for each operation.

String

message

The error message appears only for debugging/logging purposes. You must not share it with the customer. No business logic should depend on the content of the error message..

String


Was this page helpful?

Last updated: Oct 31, 2024