Skip to content

Instantly share code, notes, and snippets.

@mlopezr
mlopezr / videoPlayer-apl1.1-v02.json
Created November 5, 2019 10:55
VideoPlayer with auto-hiding overlay in APL 1.1
{
"type": "APL",
"version": "1.1",
"import": [
{
"name": "alexa-layouts",
"version": "1.1.0"
}
],
"mainTemplate": {
@mlopezr
mlopezr / responsive-splash-screen.json
Last active August 27, 2019 09:32
Responsive APL Splash Screen with logo and hint
{
"document": {
"type": "APL",
"version": "1.0",
"theme": "dark",
"import": [],
"resources": [],
"styles": {},
"layouts": {
"ResponsiveSplashLayout": {
@mlopezr
mlopezr / Sample question component for quiz skill using APL.md
Last active August 2, 2019 13:12
Sample APL for quiz skill: pager with result of last question and next question

Sample question component for quiz skill using APL

This is a sample APL for a quiz result and question.

It includes both the APL document and sample data sources.

Tweak it

@mlopezr
mlopezr / terraform-fiware-lab.tf
Created September 10, 2015 16:12
Simple example of using terraform.io to provision on FIWARE Lab Cloud a VM instance with a public IP and firewalling rules
### Variables ###
# Variables can be set by exporting environment variable TF_VAR_varname
variable keypair {
description = "SSH keypair to be used for VM authentication. The keypair should already be registered in FIWARE Lab Cloud."
}
variable image_id {
default = "7f2b4b3e-1cda-4e16-a09a-a97c600f78c0"
@mlopezr
mlopezr / README.md
Last active March 14, 2019 14:11
Running Alexa skills from your local machine

Running Alexa skills from your local machine

Talk to Alexa skills running on your local machine. Stop waiting for Lambda deployments. Debug step-by-step.

Setup

  • Find the index.js file containing your ASK SDK NodeJS skill handler code (usually in skill-name/lambda/custom)
  • Add server.js to the same folder where index.js is located
@mlopezr
mlopezr / server.js
Last active March 13, 2019 21:52
Sample server to run Alexa skill on your machine, to be used with ngrok
const express = require('express');
const bodyParser = require('body-parser');
const handler = require('./index').handler;
function CreateHandler(handler) {
return (req, res) => {
handler(req.body, null, (err, result) => {
if (err) {
return res.status(500).send(err);
@mlopezr
mlopezr / zapier-matrix.js
Created September 6, 2016 23:52
Zapier script to integrate with matrix.org chatrooms
'use strict';
var Zap = {
get_session_info: function(bundle) {
/*
Argument:
bundle.request.url: <string>
bundle.request.headers: <object>
bundle.request.params: <object> # this will be mapped into the querystring
@mlopezr
mlopezr / full-response-with-commands.json
Last active January 18, 2019 10:40
Sample Spoken Horizontal List
{
"directives": [
{
"type": "Alexa.Presentation.APL.RenderDocument",
"token": "intro",
"document": {
"type": "APL",
"version": "1.0",
"theme": "dark",
"import": [],
@mlopezr
mlopezr / README.md
Last active November 19, 2017 10:04
Scrape Alexa Skills Kit Documentation to eBook

Keybase proof

I hereby claim:

  • I am mlopezr on github.
  • I am mariolr (https://keybase.io/mariolr) on keybase.
  • I have a public key whose fingerprint is 350A ECC7 9149 45E6 8757 04A0 8353 BB07 494E 7074

To claim this, I am signing this object: