I just add a new method to the response builder to be able to pass as param an audio metadata to the play directive.
Motivation and Context
I have a skill where I need to display metadata on AudioPlayer. At first, I did this replicating the code in the addAudioPlayerPlayDirective method. Once it worked I decided to add a new helper method in the response builder to cover that scenario.
Testing
First of all, I replicated the code from addAudioPlayerPlayDirective adding the line for the audio item metadata. I tested that on my Echo Show 5 (and other people did as well).
Once it worked, I moved that code to a new method in the ResponseBuilder class in the sdk. I decided to refactor the code a little bit so both addAudioPlayerPlayDirective use the same final code to build the directive.
I installed the dependency in local and tested it as a I did with my first version on my own code.
Screenshots
Types of changes
[ ] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)
Checklist
[x] My code follows the code style of this project
[ ] My change requires a change to the documentation
[ ] I have updated the documentation accordingly
[x] I have read the README document
[x] I have added tests to cover my changes
[x] All new and existing tests passed
License
[x] By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
Description
I just add a new method to the response builder to be able to pass as param an audio metadata to the play directive.
Motivation and Context
I have a skill where I need to display metadata on AudioPlayer. At first, I did this replicating the code in the
addAudioPlayerPlayDirective
method. Once it worked I decided to add a new helper method in the response builder to cover that scenario.Testing
First of all, I replicated the code from
addAudioPlayerPlayDirective
adding the line for the audio item metadata. I tested that on my Echo Show 5 (and other people did as well). Once it worked, I moved that code to a new method in theResponseBuilder
class in the sdk. I decided to refactor the code a little bit so bothaddAudioPlayerPlayDirective
use the same final code to build the directive. I installed the dependency in local and tested it as a I did with my first version on my own code.Screenshots
Types of changes
Checklist
License