Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Having trouble in channelController #53

Closed
VijayKrishna91 opened this issue Mar 1, 2018 · 1 comment
Closed

Having trouble in channelController #53

VijayKrishna91 opened this issue Mar 1, 2018 · 1 comment
Assignees

Comments

@VijayKrishna91
Copy link

My skill is working fine for powerController, sceneController etc..
But with channelController i am facing problem, It's very irritating there is no clear message where it's failing,.
I checked my lambda for logs i find everything right even channel is changed(Action happening as expected) but alexa says 'my device name' is not responding.
This is what i get in payload from alexa directive -

{
    "header": {
        "namespace": "Alexa.ChannelController",
        "name": "ChangeChannel",
        "payloadVersion": "3",
        "messageId": "SOMEID",
        "correlationToken": "SOME_TOKEN"
    },
    "endpoint": {
        "scope": {
            "type": "BearerToken",
            "token": "SomeBearerToken"
        },
        "endpointId": "5a27c092914b9b7dee318fc7",
        "cookie": {
            "kd_id": "6001941a6601",
            "type": "irApp"
        }
    },
    "payload": {
        "channel": {
            "number": "201"
        },
        "channelMetadata": {}
    }
}

And this is what i am sending in response after successful action

{
    "event": {
        "header": {
            "namespace": "Alexa",
            "name": "Response",
            "payloadVersion": "3",
            "messageId": "SOMEID",
            "correlationToken": "SOME_TOKEN"
        },
        "endpoint": {
            "scope": {
                "type": "BearerToken",
                "token": "SomeBearerToken"
            },
            "endpointId": "5a27c092914b9b7dee318fc7",
            "cookie": {
                "remote_codeset": "58c630053c8ab2bc3d3b0284",
                "paired_ud": "5a5711de57a58c0a06c3e432",
                "kd_id": "6001941a6601",
                "type": "irApp"
            }
        },
        "payload": {}
    },
    "context": {
        "properties": [
            {
                "namespace": "Alexa.ChannelController",
                "name": "channel",
                "value": {
                    "number": "201",
                    "callSign": "callsign1",
                    "affiliateCallSign": "callsign2"
                },
                "timeOfSample": "2017-02-03T16:20:50.52Z",
                "uncertaintyInMilliseconds": 0
            },
            {
                "namespace": "Alexa.EndpointHealth",
                "name": "connectivity",
                "value": {
                    "value": "OK"
                },
                "timeOfSample": "Thu Mar 01 2018 17:53:01 GMT+0530 (IST)",
                "uncertaintyInMilliseconds": 200
            }
        ]
    }
}

My server responds to alexa within 200-300ms still alexa tells the 'my device' is not responding.

I am stuck at this thing for 3 days.. Is there something wrong with the response of channelController responseformat.. ?

@dievaa dievaa self-assigned this Nov 16, 2023
@dievaa
Copy link
Contributor

dievaa commented Nov 16, 2023

According to the ChangeChannel directive you are receiving, you did not have all the channel properties like "callSign" and "affiliateCallSign" for that channel. So, as you need to include in the “context” object the values of all properties that changed, you have to include only the properties received in the ChangeChannel directive, in this case "number": "201".

In addition, you may also need to include "Alexa.PowerController" in the ChangeChannel response, as per the following example: https://developer.amazon.com/en-US/docs/alexa/device-apis/alexa-channelcontroller.html#changechannel-response-event

If the suggestions above didn't resolve the issue, please do not hesitate to reach out to us via the Contact Us page providing the Customer ID and Timestamp in UTC of a recent error.

@dievaa dievaa closed this as completed Nov 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants