Skip to content

Instantly share code, notes, and snippets.

View zdne's full-sized avatar
💭
🚀

Z zdne

💭
🚀
View GitHub Profile
@zdne
zdne / stuff.md
Last active January 14, 2017 20:22
  1. Retrieve WeatherReport where address is Anchorage, Alaska
  2. Send Payment where the recipient is https://keybase.io/phil and currency is USD and amount is 40
  3. Send Message where the recipient is https://keybase.io/phil and text is Hey Phil ...
# Using a terms from schema.org dictionary,
# find services that offers WeatherForecast.
services = apiRegistry.find(WeatherForecast, { vocabulary: "http://schema.org"})
# Query a service for WeatherForecast at GeoCoordinates.
forecast = service.retrieve(WeatherForecast, { GeoCoordinates: … })
# Display Temperature
print forecast(Temperature)

Keybase proof

I hereby claim:

  • I am zdne on github.
  • I am zdenek (https://keybase.io/zdenek) on keybase.
  • I have a public key whose fingerprint is AAB0 458B 4299 95C4 5C9F 0CE0 1205 3F7F C8E6 F7A4

To claim this, I am signing this object:

# User [/users/{id}]
- Attributes (object)
- name: John
- email: john@apiary.io
## Retrieve [GET]
- Response 200 (application/json)
- Attributes (User)
## Remove [DELETE]
# API
## Globals Parameters
- version: 1.0 (string) - Version of the API
# Resource A [/{version}/some/path/to/a]
# Resource B [/{version}/some/path/to/b]
# Fizz Buzz Solving API Blueprint
## Data Structures
## Main (array)
This only does 1 through 15.
### Members
- !map
- (array)
@zdne
zdne / gist:8649615
Created January 27, 2014 14:37
Sublime Text 3 as default git editor
$ git config --global core.editor "subl -n -w"
@zdne
zdne / howto.md
Last active January 4, 2016 03:08

How to convert a legacy Apiary Blueprint to API Blueprint using CLI

CLI Tools Required

Install following CLI tools:

  1. Apiary Blueprint Parser

    $ npm install apiary-blueprint-parser
@zdne
zdne / gist:6560278
Created September 14, 2013 08:58
Example API Blueprint parser output in the JSON format
{
"_version": "1.0",
"metadata": {},
"name": "",
"description": "",
"resourceGroups": [
{
"name": "",
"description": "",
"resources": [
@zdne
zdne / vnd.apiblueprint.ast+json.json
Last active December 21, 2015 10:38
Testing new API Blueprint parameters syntax

Full-featured

NOTE: Colons are optional. Keywords are case insensitive.

  • Parameters

    • id

      Lorem ipsum dolor sit amet, consectetur adipiscing elit. In molestie justo eget diam vulputate rutrum. Donec ultrices est sed scelerisque lacinia.