{"id":18494887,"url":"https://github.com/qaware/ec24-skill","last_synced_at":"2025-07-11T19:37:24.581Z","repository":{"id":239055525,"uuid":"797089776","full_name":"qaware/ec24-skill","owner":"qaware","description":"The EC24 Alexa skill.","archived":false,"fork":false,"pushed_at":"2024-06-21T06:13:11.000Z","size":41,"stargazers_count":0,"open_issues_count":1,"forks_count":1,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-05-14T03:14:25.906Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/qaware.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-05-07T07:15:25.000Z","updated_at":"2024-05-09T17:26:06.000Z","dependencies_parsed_at":"2024-05-09T18:50:46.289Z","dependency_job_id":"4d1109e7-7168-43be-98a7-166c58fae524","html_url":"https://github.com/qaware/ec24-skill","commit_stats":null,"previous_names":["qaware/ec24-skill"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/qaware/ec24-skill","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qaware%2Fec24-skill","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qaware%2Fec24-skill/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qaware%2Fec24-skill/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qaware%2Fec24-skill/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/qaware","download_url":"https://codeload.github.com/qaware/ec24-skill/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qaware%2Fec24-skill/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264888015,"owners_count":23678790,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-06T13:22:36.389Z","updated_at":"2025-07-11T19:37:24.554Z","avatar_url":"https://github.com/qaware.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# The Engineering Camp Alexa Skill\n\nSimple Alexa demo skill to ask for the next talk in the Pretalx schedule.\n\n```bash\n# install CLI and create new skill project\nnpm install -g ask-cli\nask new\n\n# install dependencies\ncd lambda\nnpm install\nnpm install --save-dev ask-sdk-local-debug\n\n# to run and test implementation locally\nask run --region EU\nask dialog\n```\n\nOnce you have everything up and running you can start with the development\nof the skill. Either use CoPilot or the following snippets to implement the\nactual business logic.\n\n```javascript\n// a function to get the complete EC24 schedule from Pretalx\nconst https = require('https');\nfunction get(url) {\n    return new Promise((resolve, reject) =\u003e {\n        https.get(url, (res) =\u003e {\n            let data = '';\n\n            res.on('data', (chunk) =\u003e {\n                data += chunk;\n            });\n\n            res.on('end', () =\u003e {\n                resolve(data);\n            });\n\n        }).on('error', (err) =\u003e {\n            reject(err);\n        });\n    });\n}\n\n// a function to check of the timestamp is today and in the future\nfunction isTodayAndAfterCurrentTime(timestamp) {\n    const now = new Date();\n    const timestampDate = new Date(timestamp);\n\n    return now.toISOString().slice(0,10) === timestampDate.toISOString().slice(0,10) \u0026\u0026 now.getTime() \u003c timestampDate.getTime();\n}  \n```\n\nThen, add the `handle()` callback to your main intent handler. \nDone. Deploy. Test.\n```javascript\n    async handle(handlerInput) {\n        let speakOutput = 'I could not find any talks for today. Please try again later.';\n\n        await get('https://ec24.qaware.de/api/events/ec24/talks/').then(\n            (data) =\u003e {\n                console.log(data);\n                const talks = JSON.parse(data);\n\n                for (let i = 0; i \u003c talks.results.length; i++) {\n                    const talk = talks.results[i];\n                    const timestamp = talk.slot.start;\n                    if (isTodayAndAfterCurrentTime(timestamp)) {\n                        speakOutput = `The next talk is ${talk.title} by ${talk.speakers[0].name}`;\n                        break;\n                    }\n                }\n            }\n        ).catch(console.error);\n\n        return handlerInput.responseBuilder\n            .speak(speakOutput)\n            .reprompt('Anything else I can do for you?')\n            .getResponse();\n    }\n```\n\n## Maintainer\n\nM.-Leander Reimer (@lreimer), \u003cmario-leander.reimer@qaware.de\u003e\n\n## License\n\nThis software is provided under the GPL v3 open source license, read the `LICENSE` file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqaware%2Fec24-skill","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fqaware%2Fec24-skill","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqaware%2Fec24-skill/lists"}