Implement CanFulfillIntentRequest for Name-free Interaction
canfulfillintentrequest on the Alexa Skills Kit developer forum.This quick start guide describes how you can add support for the CanFulfillIntentRequest interface to your Alexa skill. By adding this support, you increase discoverability for your skill in name-free interactions. You increase the likelihood that your skill will be selected when a prospective customer, who may never have enabled your skill, asks Alexa a request, a question, or a statement without specifying a skill to fulfill it.
See also:
- Update the SDK used by your skill if applicable
- Prepare the skill manifest, interaction model, and skill-related information
- Add logic in your skill service to fulfill responses to CanFulfillIntentRequest
- Invoke and test the skill
Update the SDK used by your skill if applicable
If you have used the ASK SDK for Node.js or the ASK SDK for Java in your skill development, and you want to add support for the CanFulfillIntentRequest interface to your Alexa skill, you must update to the ASK SDK v2 for Node.js (Public beta) or ASK SDK v2 for Java (Public beta), as appropriate.
Prepare the skill manifest, interaction model, and skill-related information
These steps may now be completed through ASK CLI, or through the developer console.
Implement CanFulfillIntentRequest with ASK CLI
To set up ASK CLI, see Quick Start Alexa Skills Kit Command Line Interface. Create a new skill if desired.
If you have set up ASK CLI and are now updating an existing skill, obtain the skill manifest file with this command:
$ ask api get-skill --skill-id amzn1.ask.skill.[unique-value-here] > skill.json
To add support to your skill for CanFulfillIntentRequest, edit the skill.json file, which contains the skill manifest.
Edit the skill information file to include "CAN_FULFILL_INTENT_REQUEST" as a new interface type entry. In the following sample manifest, refer to the interfaces values. Thus, "CAN_FULFILL_INTENT_REQUEST" is another interface which you as a skill developer can choose to support or not.
{
"manifest":{
"manifestVersion":"1.0",
"publishingInformation":{
"locales":{
"en-US":{
"name":"MySkill",
"summary":"Sample Short Description",
"description":"Sample Full Description",
"examplePhrases": [
"Alexa open hello world",
"Alexa tell hello world I am Jeff",
"Alexa tell hello world my name is Peter"
]
}
},
"distributionCountries":[
"US"
],
"isAvailableWorldwide":false,
"testingInstructions":"Sample Testing Instructions",
"category":"EDUCATION_AND_REFERENCE"
},
"apis":{
"custom":{
"endpoint":{
"uri":"https://customapi-eu.sampleskill.com",
"sslCertificateType":"TRUSTED"
},
"regions":{
"NA":{
"endpoint":{
"uri":"https://customapi-na.sampleskill.com",
"sslCertificateType":"TRUSTED"
}
}
},
"interfaces":[
{
"type":"VIDEO_APP"
},
{
"type":"RENDER_TEMPLATE"
},
{
"type":"AUDIO_PLAYER"
},
{
"type":"CAN_FULFILL_INTENT_REQUEST"
}
]
}
}
}
}
Update or create your skill in ASK CLI
You can now use the command-line interface to update or create the new skill definition.
If you are updating an existing skill, use:
$ ask api update-skill --skill-id amzn1.ask.skill.[unique-value-here] --file /path/to/skill/information/file
If you are creating a new skill, use:
$ ask api create-skill --file /path/to/skill/information/file
Implement CanFulfillIntentRequest through the developer console
Open your skill in the developer console. Go to the Build > Custom > Interfaces page, and enable the CanFulfillIntentRequest interface.

Scroll to the top of the panel, and then click Save Interfaces. In the bottom right, a message should appear indicating that the skill manifest saved successfully.

Add logic in your skill service to fulfill responses to CanFulfillIntentRequest
Whether you have implemented CanFulfillIntentRequest with ASK CLI or through the developer console, the steps to implement the logic in your skill are the same.
See Understand Name-free Interaction for Custom Skills.
Invoke and test the skill
After you've updated your skill manifest and updated the code for your skill service, you can invoke the skill from ASK CLI or the developer console to test your skill's response.
Create the JSON for testing your skill
Create a new .json file containing the input JSON with the request type set to CanFulfillIntentRequest.
The following is a sample .json file for the request:
{
"session":{
"new": true,
"sessionId":"SessionId.[unique-value-here]",
"application":{
"applicationId":"amzn1.ask.skill.[unique-value-here]"
},
"attributes":{
"key": "string value"
},
"user":{
"userId":"amzn1.ask.account.[unique-value-here]"
}
},
"request":{
"type":"CanFulfillIntentRequest",
"requestId":"EdwRequestId.[unique-value-here]",
"intent":{
"name":"MyNameIsIntent",
"slots":{
"name":{
"name":"name",
"value":"Jeff"
}
}
},
"locale":"en-US",
"timestamp":"2017-10-03T22:02:29Z"
},
"context":{
"AudioPlayer":{
"playerActivity":"IDLE"
},
"System":{
"application":{
"applicationId":"amzn1.ask.skill.[unique-value-here]"
},
"user":{
"userId":"amzn1.ask.account.[unique-value-here]"
},
"device":{
"supportedInterfaces":{
}
}
}
},
"version":"1.0"
}
Test the skill using ASK CLI
To invoke the skill from ASK CLI, use the following command:
$ ask api invoke-skill --skill-id amzn1.ask.skill.[unique-value-here] --file /path/to/input/json --endpoint-region [endpoint-region-here]
This command writes your skill's response to the CanFulfillIntentRequest to standard output.
Test the skill using the developer console
- In the developer console, click the Test tab.
- Click Manual JSON.
- In the text box, enter the JSON for a
CanFulfillIntentRequestthat invokes the endpoint for your skill.

For an example .json file, see create the JSON for testing your skill.
Scenarios to test
Whether you are testing in ASK CLI or in the developer console, make sure to test across the following scenarios:
- Verify that your skill handles a
CanFulfillIntentRequestcall with nouserIdpresent. - Verify that your skill handles a
CanFulfillIntentRequestcall with no session information present. - Verify that your skill handles a
CanFulfillIntentRequestcall for each intent that your skill supports.