updated oauth scheme;

updated oauth scheme;

description: OAuth 2.0 for authenticating all API requests.
type: OAuth 2.0
describedBy:
  headers:
    Authorization:
      description: |
        Used to send a valid OAuth 2 access token. Do not use
        with the "access_token" query string parameter.
      type: string
  queryParameters:
    access_token:
      description: |
        Used to send a valid OAuth 2 access token. Do not use together with
        the "Authorization" header
      type: string
  responses:
    400:
      description: Bad OAuth request.
      body:
        application/json:
          example: !include ../samples/response-status/400.sample
    401:
      description: |
        Bad or expired token. This can happen if the user or Dropbox
        revoked or expired an access token. To fix, you should re-
        authenticate the user.
      body:
        application/json:
          example: !include ../samples/response-status/401.sample
    403:
      description: |
        Bad OAuth request (wrong consumer key, bad nonce, expired
        timestamp...). Unfortunately, re-authenticating the user won't help here.
      body:
        application/json:
          example: !include ../samples/response-status/403.sample
    404:
      description: OAuth resurce not found.
      body:
        application/json:
          example: !include ../samples/response-status/404.sample
    405:
      description: Method of OAuth request is not allowed.
      body:
        application/json:
          example: !include ../samples/response-status/405.sample
    409:
      description: Conflict in request.
      body:
        application/json:
          example: !include ../samples/response-status/409.sample
    410:
      description: OAuth resource is not available.
      body:
        application/json:
          example: !include ../samples/response-status/410.sample
    500:
      description: Internal server error.
      body:
        application/json:
          example: !include ../samples/response-status/500.sample
    503:
      description: Service is unavailable.
      body:
        application/json:
          example: !include ../samples/response-status/503.sample
settings:
  authorizationUri: https://console.cpdn.sd2.cz/authorize
  accessTokenUri: https://console.cpdn.sd2.cz/oauth/token
  authorizationGrants: [ code, token ]

description: OAuth 2.0 for authenticating all API requests.
type: OAuth 2.0
describedBy:
  headers:
    Authorization:
      description: |
        Used to send a valid OAuth 2 access token. Do not use
        with the "access_token" query string parameter.
      type: string
  queryParameters:
    access_token:
      description: |
        Used to send a valid OAuth 2 access token. Do not use together with
        the "Authorization" header
      type: string
  responses:
    401:
      description: |
        Bad or expired token. This can happen if the user or Dropbox
        revoked or expired an access token. To fix, you should re-
        authenticate the user.
    403:
      description: |
        Bad OAuth request (wrong consumer key, bad nonce, expired
        timestamp...). Unfortunately, re-authenticating the user won't help here.
settings:
  authorizationUri: https://oauth.cpdn.sd2.cz/authorize
  accessTokenUri: https://oauth.cpdn.sd2.cz/token
  authorizationGrants: [ code, token ]


document containerPort 0 in raml

document containerPort 0 in raml

Summary: this is documented elsewhere; I put it here for additional clarity

Test Plan: n/a

Reviewers: jdef, unterstein, jenkins, kensipe

Reviewed By: jdef, jenkins, kensipe

Subscribers: marathon-dev

Differential Revision: https://phabricator.mesosphere.com/D795

#%RAML 1.0 Library
uses:
  label: label.raml
  numbers: numberTypes.raml
  strings: stringTypes.raml
  pragma: pragma.raml
types:
  Endpoint:
    type: object
    description: |
      Endpoints accept connections from outside of a pod.
      Endpoints may also be advertised outside of a cluster.
    properties:
      name:
        type: strings.Name
        description: |
          Name of this port. Should be unique in the context of the pod.
      containerPort?:
        type: numbers.Port
        description: |
          The container port that a task's process is actually listening on.
          Required if the network mode is container
        usage: Specify 0 to tell Marathon to match the dynamically allocated host port.
      hostPort?:
        type: numbers.AnyPort
        description: |
          Mapped port on the host.
          All host ports are allocated from resource offers.
        usage: Specify 0 to tell Marathon to dynamically allocate a host port.
      protocol?:
        type: array
        (pragma.omitEmpty):
        items: strings.Name
        minItems: 1
        description: |
          The protocol of this port, advertised in Mesos DiscoveryInfo (DI).
          Specifying more than one protocol here will result in the generation
          of multiple Port DI entries.
      labels?:
        type: label.KVLabels
        (pragma.omitEmpty):
        description: |
          Metadata as key/value pair. Possible uses include VIPs,
          per-network-interface binding
      networkNames?:
        type: array
        items: strings.Name
        description: |
          List of the container networks associated with this endpoint. If
          absent, then this endpoint is associated with all defined container
          networks (for this application). A single item list is mandatory when
          `hostPort` is specified and multiple container networks are defined.
        (pragma.omitEmpty):
  NetworkMode:
    type: string
    enum: [container, "container/bridge", host]
    description: |
      `container` networks are named networks and are assigned an IP address by Mesos.
      The `container/bridge` network is a special container network that operates in a
      manner similar to Docker's "default bridge" mode, and depends on specific Mesos
      CNI support. The `host` network results in containers sharing the network namespace
      of the Mesos agent, and no IP address is allocated.
  Network:
    type: object
    properties:
      name?:
        type: strings.Name
        description: |
          Defines the name of the container network to join.
          Not for use with `host` mode networking.
      mode?:
        type: NetworkMode
        default: container
      labels?:
        type: label.KVLabels
        (pragma.omitEmpty):
        description: |
          Labels applied to the pod's NetworkInfo.
          Ignored when using `host` node networking.
  IpDiscoveryPort:
    type: object
    description: Port
    properties:
      number?:
        type: numbers.AnyPort
        description: The port number
        default: 0
      name:
        type: strings.LegacyName
        description: Name of the port
      protocol?:
        type: strings.NetworkProtocol
        default: tcp
      labels?:
        type: label.KVLabels
        (pragma.omitEmpty):
  IpDiscovery:
    type: object
    description: Information useful for service discovery
    properties:
      ports?:
        type: IpDiscoveryPort[]
        (pragma.omitEmpty):
        description: |
          Array of objects describing the ports exposed by each task
  IpAddress:
    type: object
    (pragma.deprecated): Experimental API that is now deprecated. Prefer portMappings
    description: |
      If an application definition includes the 'ipAddress' field, then Marathon
      will request a per-task IP from Mesos.
      A separate ports/portMappings configuration is then disallowed.
    properties:
      discovery?:
        type: IpDiscovery
        description: |
          DEPRECATED. Please try to use portMappings instead.
      groups?:
        type: array
        (pragma.omitEmpty):
        description: Ignored by Marathon, only exists here to preserve API compat (for now).
        items: string
        uniqueItems: true
      labels?:
        type: label.KVLabels
        (pragma.omitEmpty):
      networkName?:
        type: string
        description: |
          If present, declares the name of the network that the container should
          join.
          In practice it is up to the IPAM to decide how to interpret this field
        minLength: 1
  PortDefinition:
    type: object
    properties:
      port?:
        type: numbers.AnyPort
        default: 0
        description: |
          If requirePorts is set to true, then this port number will be used
          on the agent host. Otherwise if the requirePorts is set to false and
          this port number is not zero, then it will be used as a service port
          and a dynamic port will be used on the agent host.
          If it is set to zero, a dynamic port will be used on the host and a
          unique service port will be assigned by Marathon.
      labels?:
        type: label.KVLabels
        (pragma.omitEmpty):
      name?:
        type: strings.LegacyName
        description: |
          Name of the service hosted on this port.
          If provided, it must be unique over all port definitions.
      protocol?:
        type: strings.NetworkProtocol
        default: tcp
        description: If this port is used for tcp or udp or both.

#%RAML 1.0 Library
uses:
  label: label.raml
  numbers: numberTypes.raml
  strings: stringTypes.raml
  pragma: pragma.raml
types:
  Endpoint:
    type: object
    description: |
      Endpoints accept connections from outside of a pod.
      Endpoints may also be advertised outside of a cluster.
    properties:
      name:
        type: strings.Name
        description: |
          Name of this port. Should be unique in the context of the pod.
      containerPort?:
        type: numbers.Port
        description: |
          The container port that a task's process is actually listening on.
          Required if the network mode is container
      hostPort?:
        type: numbers.AnyPort
        description: |
          Mapped port on the host.
          All host ports are allocated from resource offers.
        usage: Specify 0 to tell Marathon to dynamically allocate a host port.
      protocol?:
        type: array
        (pragma.omitEmpty):
        items: strings.Name
        minItems: 1
        description: |
          The protocol of this port, advertised in Mesos DiscoveryInfo (DI).
          Specifying more than one protocol here will result in the generation
          of multiple Port DI entries.
      labels?:
        type: label.KVLabels
        (pragma.omitEmpty):
        description: |
          Metadata as key/value pair. Possible uses include VIPs,
          per-network-interface binding
      networkNames?:
        type: array
        items: strings.Name
        description: |
          List of the container networks associated with this endpoint. If
          absent, then this endpoint is associated with all defined container
          networks (for this application). A single item list is mandatory when
          `hostPort` is specified and multiple container networks are defined.
        (pragma.omitEmpty):
  NetworkMode:
    type: string
    enum: [container, "container/bridge", host]
    description: |
      `container` networks are named networks and are assigned an IP address by Mesos.
      The `container/bridge` network is a special container network that operates in a
      manner similar to Docker's "default bridge" mode, and depends on specific Mesos
      CNI support. The `host` network results in containers sharing the network namespace
      of the Mesos agent, and no IP address is allocated.
  Network:
    type: object
    properties:
      name?:
        type: strings.Name
        description: |
          Defines the name of the container network to join.
          Not for use with `host` mode networking.
      mode?:
        type: NetworkMode
        default: container
      labels?:
        type: label.KVLabels
        (pragma.omitEmpty):
        description: |
          Labels applied to the pod's NetworkInfo.
          Ignored when using `host` node networking.
  IpDiscoveryPort:
    type: object
    description: Port
    properties:
      number?:
        type: numbers.AnyPort
        description: The port number
        default: 0
      name:
        type: strings.LegacyName
        description: Name of the port
      protocol?:
        type: strings.NetworkProtocol
        default: tcp
      labels?:
        type: label.KVLabels
        (pragma.omitEmpty):
  IpDiscovery:
    type: object
    description: Information useful for service discovery
    properties:
      ports?:
        type: IpDiscoveryPort[]
        (pragma.omitEmpty):
        description: |
          Array of objects describing the ports exposed by each task
  IpAddress:
    type: object
    (pragma.deprecated): Experimental API that is now deprecated. Prefer portMappings
    description: |
      If an application definition includes the 'ipAddress' field, then Marathon
      will request a per-task IP from Mesos.
      A separate ports/portMappings configuration is then disallowed.
    properties:
      discovery?:
        type: IpDiscovery
        description: |
          DEPRECATED. Please try to use portMappings instead.
      groups?:
        type: array
        (pragma.omitEmpty):
        description: Ignored by Marathon, only exists here to preserve API compat (for now).
        items: string
        uniqueItems: true
      labels?:
        type: label.KVLabels
        (pragma.omitEmpty):
      networkName?:
        type: string
        description: |
          If present, declares the name of the network that the container should
          join.
          In practice it is up to the IPAM to decide how to interpret this field
        minLength: 1
  PortDefinition:
    type: object
    properties:
      port?:
        type: numbers.AnyPort
        default: 0
        description: |
          If requirePorts is set to true, then this port number will be used
          on the agent host. Otherwise if the requirePorts is set to false and
          this port number is not zero, then it will be used as a service port
          and a dynamic port will be used on the agent host.
          If it is set to zero, a dynamic port will be used on the host and a
          unique service port will be assigned by Marathon.
      labels?:
        type: label.KVLabels
        (pragma.omitEmpty):
      name?:
        type: strings.LegacyName
        description: |
          Name of the service hosted on this port.
          If provided, it must be unique over all port definitions.
      protocol?:
        type: strings.NetworkProtocol
        default: tcp
        description: If this port is used for tcp or udp or both.


rounding out api docs intro section

rounding out api docs intro section

#%RAML 0.8

title: Ephemeral Container Service (ECS) (%ECS_VERSION%)
version: v99.999
documentation:
  - title: Overview
    content: |
      The Ephemeral Container Service (ECS) was born out of
      the [Cloudfeaster](https://github.com/simonsdave/cloudfeaster.git) project.
      [Docker](https://www.docker.com/) makes it easy to package
      short lived (aka ephemeral) tasks in a docker image and run
      those tasks using
      the [Docker Remote API](https://docs.docker.com/engine/reference/api/docker_remote_api/).
      ECS adds a service on top these building blocks that allows ephemeral tasks
      to be run on a cluster of [CoreOS](https://coreos.com/) machines using a RESTful API.

  - title: Security
    content: |
      In-transit - All communication with an ECS deployment is done over SSL/TLS.
      The ECS runs on a cluster of [CoreOS](https://coreos.com/) machines
      with a layer 5 (TCP) load balancer running in front of the cluster.
      Layer 5 load balancing is required because [nginx](http://nginx.org)
      is used to terminate SSL/TLS on each node in the cluster.

      At-rest - The ECS does not persist any data.

      Authentication ...

      Authorization - the ECS is intended to be used a low level, utility service
      sitting behind a higher level abstractions that implements authorization.
      As such, the ECS has no authorization.
      As soon as a requestor is authenticated they are able to access
      any of ECS' endpoints.

  - title: Performance Expectations
    content: |
      In the API docs you'll notice a *Performance Expectations* section for
      endpoint operations. These performance expectations describe the expected
      time to perform the requested operation **after** the request has reached
      the service code which implements the operation. In order to estimate expected
      time to perform an operation from your infrastructure, record the time it
      takes to send repeated requests to the ```/_noop``` endpoint and
      add this ```/_noop``` time to the performance expectation described in the
      API docs.

  - title: Scaling
    content: |
      The ECS runs on a cluster of [CoreOS](https://coreos.com/) machines
      with a layer 5 load balancer running in front of the cluster.
      Each node in the cluster runs the ECS service and schedules tasks
      on that node.
      From an ECS point of view, there are no dependancies between nodes and
      as such the ECS cluster is intended to scale horizontally to accommadate
      a broad variety of workloads.

/tasks:
  displayName: Tasks
  description: |
    The ```/tasks``` endpoint enables creation and execution of tasks
  post:
    description: |
      Create and execute a task.

      ##### Authentication
        * None

      ##### Performance Expectations
        * 99% of the time < nnn ms

      ##### Example
      ```bash
      >cat echo.json
      {
        "docker_image": "ubuntu",
        "tag": "latest",
        "cmd": [
          "echo",
          "hello world!!!"
        ]
      }
      >curl \
        -s \
        -X POST \
        -H "Content-Type: application/json" \
        --data-binary @echo.json \
        $ECS_ENDPOINT/v1.0/tasks | \
        jq
      {
        "stdout": "aGVsbG8gd29ybGQhISEK",
        "stderr": "",
        "exitCode": 0
      }
      > python
      Python 2.7.6 (default, Jun 22 2015, 17:58:13)
      [GCC 4.8.2] on linux2
      Type "help", "copyright", "credits" or "license" for more information.
      >>> import base64
      >>> base64.b64decode('aGVsbG8gd29ybGQhISEK')
      'hello world!!!\n'
      >>>
      ```
    responses:
      200:
        description:
          Success!
      400:
        description:
          Bad request.

/_version:
  displayName: Version
  description: |
    The ```/_version``` endpoint reports
    returns the ECS' version.
  get:
    description: |
      The endpoint always returns 200 OK and includes the services'
      version number in the body.

      ##### Authentication
        * None

      ##### Performance Expectations
        * 99% of the time < 50 ms

      ##### Example
      ```bash
      >curl -s $ECS_ENDPOINT/v1.0/_version | jq
      {
        "version": "0.8.0",
        "links": {
          "self": {
            "href": "$ECS_ENDPOINT/v1.0/_version"
          }
        }
      }
      >
      ```
    responses:
      200:
        description:
          200 OK is always returned by this endpoint.

/_noop:
  displayName: NoOp
  description: |
    The ```/_noop``` endpoint is intended to be used
    for assessing a deployment's performance.
  get:
    description: |
      The endpoint always returns 200 OK after doing nothing ie. it's a no-op.
      The intended purpose of this endpoint is to measure how long it takes
      for a caller and the service to establish a secure connection
      and complete a request/response roundtrip.

      ##### Authentication
        * None

      ##### Performance Expectations
        * 99% of the time < 50 ms

      ##### Example
      ```bash
      >curl \
        -s \
        -o /dev/null \
        -w %{http_code}\\n \
        $ECS_ENDPOINT/v1.0/_noop
      200
      >
      ```
    responses:
      200:
        description:
          200 OK is always returned by this endpoint.

/_health:
  displayName: Health
  description: |
    An HTTP GET to the ```/_health``` endpoint returns a JSON document
    which describes the health of the service.
  get:
    description: |
      The JSON document returned by an HTTP GET to the ```/_health```
      endpoint and the HTTP status code describe the health of the service.
      An HTTP status code of 200 OK is healthy and anything else is unhealthy.
      The top level "status" property in the JSON document will be "green" if the service
      is healthy and "red" if there's a problem.
      The "details" property of the JSON document contains a red/green style health entry
      for each service's components.
      The overall health is "red" if any of the dependant services are unhealthy.

      Two types of health check are possible. A quick health check
      does not confirm the health of all service components and will
      respond quickly. A comprehensive health check does check
      all service components. The ```quick``` query string parameter
      takes a boolean value to determine if a quick or comprehensive
      health check is performed.

      ##### Authentication
        * None (for now)

      ##### Usage Expectations
        * the external monitoring service will perform a quick health check every minute
        * the external monitoring service will perform a comprehensive health check 5 minutes
        * a load balancer sitting in front of the app tier will repeatedly and
          frequently issue a quick health check

      ##### Performance Expectations
        * quick - 99% of the time < 50 ms
        * comprehensive - 99% of the time < 3,050 ms
          (note 3,050 is determined by taking the default value for the
          ```max_time_in_ms_to_wait_for_component_health_checks```
          configuration option and adding 50 ms ie. changing the
          configuration option can be used to change the performance
          characteristics of the endpoint)

      ##### Example
      For example, below a sample of a healthy response to a request
      for a quick health check.

      ```bash
      >curl \
        -s \
        $ECS_ENDPOINT/v1.0/_health?quick=false | \
        jq
      {
        "status": "green",
        "details": {
          "docker remote api": {
            "status": "green",
            "details": {
              "connectivity": "green",
              "api version": "green"
            }
          }
        },
        "links": {
          "self": {
            "href": "$ECS_ENDPOINT/v1.0/_health"
          }
        }
      }
      >
      ```

    queryParameters:
      quick:
        displayName: quick
        type: boolean
        description:
          Determines if a quick or deep health check is performed.
          quick is true by default.
        example: true
        required: false
    responses:
      200:
        description:
          When everything is green a 200 OK is returned.
      500:
        description:
          something super nasty happened inside the service
      503:
        description:
          When something is red a 503 service unavailable is returned.

#%RAML 0.8

title: Ephemeral Container Service (ECS) (%ECS_VERSION%)
version: v99.999
documentation:
  - title: Overview
    content: |
      * ...
  - title: Key Concepts
    content: |
      * task packaged inside a docker container
      * emphemeral = short lived, no state

/tasks:
  displayName: Tasks
  description: |
    The ```/tasks``` endpoint enables creation and execution of tasks
  post:
    description: |
      Create and execute a task.

      ##### Authentication
        * None

      ##### Performance Expectations
        * 99% of the time < nnn ms

      ##### Example
      ```bash
      >cat echo.json
      {
        "docker_image": "ubuntu",
        "tag": "latest",
        "cmd": [
          "echo",
          "hello world!!!"
        ]
      }
      >curl \
        -s \
        -X POST \
        -H "Content-Type: application/json" \
        --data-binary @echo.json \
        http://127.0.0.1:8445/v1.0/tasks | \
        jq
      {
        "stdout": "aGVsbG8gd29ybGQhISEK",
        "stderr": "",
        "exitCode": 0
      }
      > python
      Python 2.7.6 (default, Jun 22 2015, 17:58:13)
      [GCC 4.8.2] on linux2
      Type "help", "copyright", "credits" or "license" for more information.
      >>> import base64
      >>> base64.b64decode('aGVsbG8gd29ybGQhISEK')
      'hello world!!!\n'
      >>>
      ```
    responses:
      200:
        description:
          Success!
        body:
          application/json:
            schema: !include ../ecs/jsonschemas/create_tasks_request.json
      400:
        description:
          Bad request.

/_version:
  displayName: Version
  description: |
    The ```/_version``` endpoint reports
    returns the ECS' version.
  get:
    description: |
      The endpoint always returns 200 OK and includes the services'
      version number in the body.

      ##### Authentication
        * None

      ##### Example
      ```bash
      >curl -s http://127.0.0.1:8448/v1.0/_version | jq
      {
        "version": "0.8.0",
        "links": {
          "self": {
            "href": "http://127.0.0.1:8448/v1.0/_version"
          }
        }
      }
      >
      ```
    responses:
      200:
        description:
          200 OK is always returned by this endpoint.

/_noop:
  displayName: NoOp
  description: |
    The ```/_noop``` endpoint is intended to be used
    for assessing a deployment's performance.
  get:
    description: |
      The endpoint always returns 200 OK after doing nothing ie. it's a no-op.
      The intended purpose of this endpoint is to measure how long it takes
      for a caller and the service to establish a secure connection
      and complete a request/response roundtrip.

      ##### Authentication
        * None

      ##### Example
      ```bash
      >curl \
        -s \
        -o /dev/null \
        -w %{http_code}\\n \
        http://127.0.0.1:8445/v1.0/_noop
      200
      >
      ```
    responses:
      200:
        description:
          200 OK is always returned by this endpoint.
        body:
          application/json:

/_health:
  displayName: Health
  description: |
    An HTTP GET to the ```/_health``` endpoint returns a JSON document
    which describes the health of the service.
  get:
    description: |
      The JSON document returned by an HTTP GET to the ```/_health```
      endpoint and the HTTP status code describe the health of the service.
      An HTTP status code of 200 OK is healthy and anything else is unhealthy.
      The top level "status" property in the JSON document will be "green" if the service
      is healthy and "red" if there's a problem.
      The "details" property of the JSON document contains a red/green style health entry
      for each service's components.
      The overall health is "red" if any of the dependant services are unhealthy.

      Two types of health check are possible. A quick health check
      does not confirm the health of all service components and will
      respond quickly. A comprehensive health check does check
      all service components. The ```quick``` query string parameter
      takes a boolean value to determine if a quick or comprehensive
      health check is performed.

      ##### Authentication
        * None (for now)

      ##### Usage Expectations
        * the external monitoring service will perform a quick health check every minute
        * the external monitoring service will perform a comprehensive health check 5 minutes
        * a load balancer sitting in front of the app tier will repeatedly and
          frequently issue a quick health check

      ##### Performance Expectations
        * quick - 99% of the time < 50 ms
        * comprehensive - 99% of the time < 3,050 ms
          (note 3,050 is determined by taking the default value for the
          ```max_time_in_ms_to_wait_for_component_health_checks```
          configuration option and adding 50 ms ie. changing the
          configuration option can be used to change the performance
          characteristics of the endpoint)

      ##### Example
      For example, below a sample of a healthy response to a request
      for a quick health check.

      ```bash
      >curl \
        -s \
        http://127.0.0.1:8445/v1.0/_health?quick=false | \
        jq
      {
        "status": "green",
        "details": {
          "docker remote api": {
            "status": "green",
            "details": {
              "connectivity": "green",
              "api version": "green"
            }
          }
        },
        "links": {
          "self": {
            "href": "http://127.0.0.1:8445/v1.0/_health"
          }
        }
      }
      >
      ```

    queryParameters:
      quick:
        displayName: quick
        type: boolean
        description:
          Determines if a quick or deep health check is performed.
          quick is true by default.
        example: true
        required: false
    responses:
      200:
        description:
          When everything is green a 200 OK is returned.
      500:
        description:
          something super nasty happened inside the service
      503:
        description:
          When something is red a 503 service unavailable is returned.


Use consistent two-space indent

Use consistent two-space indent

#%RAML 0.8

title: e-BookMobile API
baseUri: http://localhost:8081/{version}
version: v1

schemas:
  - book: !include book.schema
  - raml-util/schemas/metadata.schema: !include raml-util/schemas/metadata.schema

/rmbtests:
  /books:
    /{bookTitle}:
    get:
      queryParameters:
        author:
          displayName: Author
          type: string
          description: An author's full name
          example: Mary Roach
          required: true
        publicationYear:
          displayName: Pub Year
          type: number
          description: The year released for the first time in the US
          example: 1984
          required: true
        rating:
          displayName: Rating
          type: number
          description: Average rating (1-5) submitted by users
          example: 3.14
          required: false
        isbn:
          displayName: ISBN
          type: string
          minLength: 10
          example: 0321736079?
      responses:
        200:
         body:
           application/json:
            schema: book
            example: |
               {
                 "data": {
                   "id": "SbBGk",
                   "title": "Stiff: The Curious Lives of Human Cadavers",
                   "description": null,
                   "datetime": {
                     "date": "2117-08-03"
                   },
                   "genre": "science",
                   "author": "Mary Roach",
                   "link": "http://e-bookmobile.com/books/Stiff"
                 },
                 "success": true,
                 "status": 200
               }

    put:
      queryParameters:
        access_token:
          displayName: Access Token
          type: number
          description: Token giving you permission to make call
          required: true
    post:
      body:
        application/json:
          schema: book
      responses:
        201:
          body:
            application/json:
              example: !include examples/bulk.sample
          headers:
            Location:
  /test:
    post:
      body:
        application/json:
      responses:
        200:
          body:
            application/json:
        302:
          headers:
            Location: