github.com/demonoid81/moby@v0.0.0-20200517203328-62dd8e17c460/docs/api/v1.34.yaml (about)

     1  # A Swagger 2.0 (a.k.a. OpenAPI) definition of the Engine API.
     2  #
     3  # This is used for generating API documentation and the types used by the
     4  # client/server. See api/README.md for more information.
     5  #
     6  # Some style notes:
     7  # - This file is used by ReDoc, which allows GitHub Flavored Markdown in
     8  #   descriptions.
     9  # - There is no maximum line length, for ease of editing and pretty diffs.
    10  # - operationIds are in the format "NounVerb", with a singular noun.
    11  
    12  swagger: "2.0"
    13  schemes:
    14    - "http"
    15    - "https"
    16  produces:
    17    - "application/json"
    18    - "text/plain"
    19  consumes:
    20    - "application/json"
    21    - "text/plain"
    22  basePath: "/v1.34"
    23  info:
    24    title: "Docker Engine API"
    25    version: "1.34"
    26    x-logo:
    27      url: "https://docs.docker.com/images/logo-docker-main.png"
    28    description: |
    29      The Engine API is an HTTP API served by Docker Engine. It is the API the Docker client uses to communicate with the Engine, so everything the Docker client can do can be done with the API.
    30  
    31      Most of the client's commands map directly to API endpoints (e.g. `docker ps` is `GET /containers/json`). The notable exception is running containers, which consists of several API calls.
    32  
    33      # Errors
    34  
    35      The API uses standard HTTP status codes to indicate the success or failure of the API call. The body of the response will be JSON in the following format:
    36  
    37      ```
    38      {
    39        "message": "page not found"
    40      }
    41      ```
    42  
    43      # Versioning
    44  
    45      The API is usually changed in each release of Docker, so API calls are versioned to ensure that clients don't break.
    46  
    47      For Docker Engine 17.10, the API version is 1.33. To lock to this version, you prefix the URL with `/v1.33`. For example, calling `/info` is the same as calling `/v1.33/info`.
    48  
    49      Engine releases in the near future should support this version of the API, so your client will continue to work even if it is talking to a newer Engine.
    50  
    51      In previous versions of Docker, it was possible to access the API without providing a version. This behaviour is now deprecated will be removed in a future version of Docker.
    52  
    53      If the API version specified in the URL is not supported by the daemon, a HTTP `400 Bad Request` error message is returned.
    54  
    55      The API uses an open schema model, which means server may add extra properties to responses. Likewise, the server will ignore any extra query parameters and request body properties. When you write clients, you need to ignore additional properties in responses to ensure they do not break when talking to newer Docker daemons.
    56  
    57      This documentation is for version 1.34 of the API. Use this table to find documentation for previous versions of the API:
    58  
    59      Docker version  | API version | Changes
    60      ----------------|-------------|---------
    61      17.10.x | [1.33](https://docs.docker.com/engine/api/v1.33/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-33-api-changes)
    62      17.09.x | [1.32](https://docs.docker.com/engine/api/v1.32/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-32-api-changes)
    63      17.07.x | [1.31](https://docs.docker.com/engine/api/v1.31/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-31-api-changes)
    64      17.06.x | [1.30](https://docs.docker.com/engine/api/v1.30/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-30-api-changes)
    65      17.05.x | [1.29](https://docs.docker.com/engine/api/v1.29/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-29-api-changes)
    66      17.04.x | [1.28](https://docs.docker.com/engine/api/v1.28/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-28-api-changes)
    67      17.03.1 | [1.27](https://docs.docker.com/engine/api/v1.27/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-27-api-changes)
    68      1.13.1 & 17.03.0 | [1.26](https://docs.docker.com/engine/api/v1.26/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-26-api-changes)
    69      1.13.0 | [1.25](https://docs.docker.com/engine/api/v1.25/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-25-api-changes)
    70      1.12.x | [1.24](https://docs.docker.com/engine/api/v1.24/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-24-api-changes)
    71      1.11.x | [1.23](https://docs.docker.com/engine/api/v1.23/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-23-api-changes)
    72      1.10.x | [1.22](https://docs.docker.com/engine/api/v1.22/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-22-api-changes)
    73      1.9.x | [1.21](https://docs.docker.com/engine/api/v1.21/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-21-api-changes)
    74      1.8.x | [1.20](https://docs.docker.com/engine/api/v1.20/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-20-api-changes)
    75      1.7.x | [1.19](https://docs.docker.com/engine/api/v1.19/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-19-api-changes)
    76      1.6.x | [1.18](https://docs.docker.com/engine/api/v1.18/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-18-api-changes)
    77  
    78      # Authentication
    79  
    80      Authentication for registries is handled client side. The client has to send authentication details to various endpoints that need to communicate with registries, such as `POST /images/(name)/push`. These are sent as `X-Registry-Auth` header as a Base64 encoded (JSON) string with the following structure:
    81  
    82      ```
    83      {
    84        "username": "string",
    85        "password": "string",
    86        "email": "string",
    87        "serveraddress": "string"
    88      }
    89      ```
    90  
    91      The `serveraddress` is a domain/IP without a protocol. Throughout this structure, double quotes are required.
    92  
    93      If you have already got an identity token from the [`/auth` endpoint](#operation/SystemAuth), you can just pass this instead of credentials:
    94  
    95      ```
    96      {
    97        "identitytoken": "9cbaf023786cd7..."
    98      }
    99      ```
   100  
   101  # The tags on paths define the menu sections in the ReDoc documentation, so
   102  # the usage of tags must make sense for that:
   103  # - They should be singular, not plural.
   104  # - There should not be too many tags, or the menu becomes unwieldy. For
   105  #   example, it is preferable to add a path to the "System" tag instead of
   106  #   creating a tag with a single path in it.
   107  # - The order of tags in this list defines the order in the menu.
   108  tags:
   109    # Primary objects
   110    - name: "Container"
   111      x-displayName: "Containers"
   112      description: |
   113        Create and manage containers.
   114    - name: "Image"
   115      x-displayName: "Images"
   116    - name: "Network"
   117      x-displayName: "Networks"
   118      description: |
   119        Networks are user-defined networks that containers can be attached to. See the [networking documentation](https://docs.docker.com/engine/userguide/networking/) for more information.
   120    - name: "Volume"
   121      x-displayName: "Volumes"
   122      description: |
   123        Create and manage persistent storage that can be attached to containers.
   124    - name: "Exec"
   125      x-displayName: "Exec"
   126      description: |
   127        Run new commands inside running containers. See the [command-line reference](https://docs.docker.com/engine/reference/commandline/exec/) for more information.
   128  
   129        To exec a command in a container, you first need to create an exec instance, then start it. These two API endpoints are wrapped up in a single command-line command, `docker exec`.
   130    # Swarm things
   131    - name: "Swarm"
   132      x-displayName: "Swarm"
   133      description: |
   134        Engines can be clustered together in a swarm. See [the swarm mode documentation](https://docs.docker.com/engine/swarm/) for more information.
   135    - name: "Node"
   136      x-displayName: "Nodes"
   137      description: |
   138        Nodes are instances of the Engine participating in a swarm. Swarm mode must be enabled for these endpoints to work.
   139    - name: "Service"
   140      x-displayName: "Services"
   141      description: |
   142        Services are the definitions of tasks to run on a swarm. Swarm mode must be enabled for these endpoints to work.
   143    - name: "Task"
   144      x-displayName: "Tasks"
   145      description: |
   146        A task is a container running on a swarm. It is the atomic scheduling unit of swarm. Swarm mode must be enabled for these endpoints to work.
   147    - name: "Secret"
   148      x-displayName: "Secrets"
   149      description: |
   150        Secrets are sensitive data that can be used by services. Swarm mode must be enabled for these endpoints to work.
   151    - name: "Config"
   152      x-displayName: "Configs"
   153      description: |
   154        Configs are application configurations that can be used by services. Swarm mode must be enabled for these endpoints to work.
   155    # System things
   156    - name: "Plugin"
   157      x-displayName: "Plugins"
   158    - name: "System"
   159      x-displayName: "System"
   160  
   161  definitions:
   162    Port:
   163      type: "object"
   164      description: "An open port on a container"
   165      required: [PrivatePort, Type]
   166      properties:
   167        IP:
   168          type: "string"
   169          format: "ip-address"
   170        PrivatePort:
   171          type: "integer"
   172          format: "uint16"
   173          x-nullable: false
   174          description: "Port on the container"
   175        PublicPort:
   176          type: "integer"
   177          format: "uint16"
   178          description: "Port exposed on the host"
   179        Type:
   180          type: "string"
   181          x-nullable: false
   182          enum: ["tcp", "udp"]
   183      example:
   184        PrivatePort: 8080
   185        PublicPort: 80
   186        Type: "tcp"
   187  
   188    MountPoint:
   189      type: "object"
   190      description: "A mount point inside a container"
   191      properties:
   192        Type:
   193          type: "string"
   194        Name:
   195          type: "string"
   196        Source:
   197          type: "string"
   198        Destination:
   199          type: "string"
   200        Driver:
   201          type: "string"
   202        Mode:
   203          type: "string"
   204        RW:
   205          type: "boolean"
   206        Propagation:
   207          type: "string"
   208  
   209    DeviceMapping:
   210      type: "object"
   211      description: "A device mapping between the host and container"
   212      properties:
   213        PathOnHost:
   214          type: "string"
   215        PathInContainer:
   216          type: "string"
   217        CgroupPermissions:
   218          type: "string"
   219      example:
   220        PathOnHost: "/dev/deviceName"
   221        PathInContainer: "/dev/deviceName"
   222        CgroupPermissions: "mrw"
   223  
   224    ThrottleDevice:
   225      type: "object"
   226      properties:
   227        Path:
   228          description: "Device path"
   229          type: "string"
   230        Rate:
   231          description: "Rate"
   232          type: "integer"
   233          format: "int64"
   234          minimum: 0
   235  
   236    Mount:
   237      type: "object"
   238      properties:
   239        Target:
   240          description: "Container path."
   241          type: "string"
   242        Source:
   243          description: "Mount source (e.g. a volume name, a host path)."
   244          type: "string"
   245        Type:
   246          description: |
   247            The mount type. Available types:
   248  
   249            - `bind` Mounts a file or directory from the host into the container. Must exist prior to creating the container.
   250            - `volume` Creates a volume with the given name and options (or uses a pre-existing volume with the same name and options). These are **not** removed when the container is removed.
   251            - `tmpfs` Create a tmpfs with the given options. The mount source cannot be specified for tmpfs.
   252          type: "string"
   253          enum:
   254            - "bind"
   255            - "volume"
   256            - "tmpfs"
   257        ReadOnly:
   258          description: "Whether the mount should be read-only."
   259          type: "boolean"
   260        Consistency:
   261          description: "The consistency requirement for the mount: `default`, `consistent`, `cached`, or `delegated`."
   262          type: "string"
   263        BindOptions:
   264          description: "Optional configuration for the `bind` type."
   265          type: "object"
   266          properties:
   267            Propagation:
   268              description: "A propagation mode with the value `[r]private`, `[r]shared`, or `[r]slave`."
   269              enum:
   270                - "private"
   271                - "rprivate"
   272                - "shared"
   273                - "rshared"
   274                - "slave"
   275                - "rslave"
   276        VolumeOptions:
   277          description: "Optional configuration for the `volume` type."
   278          type: "object"
   279          properties:
   280            NoCopy:
   281              description: "Populate volume with data from the target."
   282              type: "boolean"
   283              default: false
   284            Labels:
   285              description: "User-defined key/value metadata."
   286              type: "object"
   287              additionalProperties:
   288                type: "string"
   289            DriverConfig:
   290              description: "Map of driver specific options"
   291              type: "object"
   292              properties:
   293                Name:
   294                  description: "Name of the driver to use to create the volume."
   295                  type: "string"
   296                Options:
   297                  description: "key/value map of driver specific options."
   298                  type: "object"
   299                  additionalProperties:
   300                    type: "string"
   301        TmpfsOptions:
   302          description: "Optional configuration for the `tmpfs` type."
   303          type: "object"
   304          properties:
   305            SizeBytes:
   306              description: "The size for the tmpfs mount in bytes."
   307              type: "integer"
   308              format: "int64"
   309            Mode:
   310              description: "The permission mode for the tmpfs mount in an integer."
   311              type: "integer"
   312  
   313    RestartPolicy:
   314      description: |
   315        The behavior to apply when the container exits. The default is not to restart.
   316  
   317        An ever increasing delay (double the previous delay, starting at 100ms) is added before each restart to prevent flooding the server.
   318      type: "object"
   319      properties:
   320        Name:
   321          type: "string"
   322          description: |
   323            - Empty string means not to restart
   324            - `always` Always restart
   325            - `unless-stopped` Restart always except when the user has manually stopped the container
   326            - `on-failure` Restart only when the container exit code is non-zero
   327          enum:
   328            - ""
   329            - "always"
   330            - "unless-stopped"
   331            - "on-failure"
   332        MaximumRetryCount:
   333          type: "integer"
   334          description: "If `on-failure` is used, the number of times to retry before giving up"
   335  
   336    Resources:
   337      description: "A container's resources (cgroups config, ulimits, etc)"
   338      type: "object"
   339      properties:
   340        # Applicable to all platforms
   341        CpuShares:
   342          description: "An integer value representing this container's relative CPU weight versus other containers."
   343          type: "integer"
   344        Memory:
   345          description: "Memory limit in bytes."
   346          type: "integer"
   347          default: 0
   348        # Applicable to UNIX platforms
   349        CgroupParent:
   350          description: "Path to `cgroups` under which the container's `cgroup` is created. If the path is not absolute, the path is considered to be relative to the `cgroups` path of the init process. Cgroups are created if they do not already exist."
   351          type: "string"
   352        BlkioWeight:
   353          description: "Block IO weight (relative weight)."
   354          type: "integer"
   355          minimum: 0
   356          maximum: 1000
   357        BlkioWeightDevice:
   358          description: |
   359            Block IO weight (relative device weight) in the form `[{"Path": "device_path", "Weight": weight}]`.
   360          type: "array"
   361          items:
   362            type: "object"
   363            properties:
   364              Path:
   365                type: "string"
   366              Weight:
   367                type: "integer"
   368                minimum: 0
   369        BlkioDeviceReadBps:
   370          description: |
   371            Limit read rate (bytes per second) from a device, in the form `[{"Path": "device_path", "Rate": rate}]`.
   372          type: "array"
   373          items:
   374            $ref: "#/definitions/ThrottleDevice"
   375        BlkioDeviceWriteBps:
   376          description: |
   377            Limit write rate (bytes per second) to a device, in the form `[{"Path": "device_path", "Rate": rate}]`.
   378          type: "array"
   379          items:
   380            $ref: "#/definitions/ThrottleDevice"
   381        BlkioDeviceReadIOps:
   382          description: |
   383            Limit read rate (IO per second) from a device, in the form `[{"Path": "device_path", "Rate": rate}]`.
   384          type: "array"
   385          items:
   386            $ref: "#/definitions/ThrottleDevice"
   387        BlkioDeviceWriteIOps:
   388          description: |
   389            Limit write rate (IO per second) to a device, in the form `[{"Path": "device_path", "Rate": rate}]`.
   390          type: "array"
   391          items:
   392            $ref: "#/definitions/ThrottleDevice"
   393        CpuPeriod:
   394          description: "The length of a CPU period in microseconds."
   395          type: "integer"
   396          format: "int64"
   397        CpuQuota:
   398          description: "Microseconds of CPU time that the container can get in a CPU period."
   399          type: "integer"
   400          format: "int64"
   401        CpuRealtimePeriod:
   402          description: "The length of a CPU real-time period in microseconds. Set to 0 to allocate no time allocated to real-time tasks."
   403          type: "integer"
   404          format: "int64"
   405        CpuRealtimeRuntime:
   406          description: "The length of a CPU real-time runtime in microseconds. Set to 0 to allocate no time allocated to real-time tasks."
   407          type: "integer"
   408          format: "int64"
   409        CpusetCpus:
   410          description: "CPUs in which to allow execution (e.g., `0-3`, `0,1`)"
   411          type: "string"
   412          example: "0-3"
   413        CpusetMems:
   414          description: "Memory nodes (MEMs) in which to allow execution (0-3, 0,1). Only effective on NUMA systems."
   415          type: "string"
   416        Devices:
   417          description: "A list of devices to add to the container."
   418          type: "array"
   419          items:
   420            $ref: "#/definitions/DeviceMapping"
   421        DeviceCgroupRules:
   422          description: "a list of cgroup rules to apply to the container"
   423          type: "array"
   424          items:
   425            type: "string"
   426            example: "c 13:* rwm"
   427        DiskQuota:
   428          description: "Disk limit (in bytes)."
   429          type: "integer"
   430          format: "int64"
   431        KernelMemory:
   432          description: "Kernel memory limit in bytes."
   433          type: "integer"
   434          format: "int64"
   435        MemoryReservation:
   436          description: "Memory soft limit in bytes."
   437          type: "integer"
   438          format: "int64"
   439        MemorySwap:
   440          description: "Total memory limit (memory + swap). Set as `-1` to enable unlimited swap."
   441          type: "integer"
   442          format: "int64"
   443        MemorySwappiness:
   444          description: "Tune a container's memory swappiness behavior. Accepts an integer between 0 and 100."
   445          type: "integer"
   446          format: "int64"
   447          minimum: 0
   448          maximum: 100
   449        NanoCPUs:
   450          description: "CPU quota in units of 10<sup>-9</sup> CPUs."
   451          type: "integer"
   452          format: "int64"
   453        OomKillDisable:
   454          description: "Disable OOM Killer for the container."
   455          type: "boolean"
   456        PidsLimit:
   457          description: "Tune a container's pids limit. Set -1 for unlimited."
   458          type: "integer"
   459          format: "int64"
   460        Ulimits:
   461          description: |
   462            A list of resource limits to set in the container. For example: `{"Name": "nofile", "Soft": 1024, "Hard": 2048}`"
   463          type: "array"
   464          items:
   465            type: "object"
   466            properties:
   467              Name:
   468                description: "Name of ulimit"
   469                type: "string"
   470              Soft:
   471                description: "Soft limit"
   472                type: "integer"
   473              Hard:
   474                description: "Hard limit"
   475                type: "integer"
   476        # Applicable to Windows
   477        CpuCount:
   478          description: |
   479            The number of usable CPUs (Windows only).
   480  
   481            On Windows Server containers, the processor resource controls are mutually exclusive. The order of precedence is `CPUCount` first, then `CPUShares`, and `CPUPercent` last.
   482          type: "integer"
   483          format: "int64"
   484        CpuPercent:
   485          description: |
   486            The usable percentage of the available CPUs (Windows only).
   487  
   488            On Windows Server containers, the processor resource controls are mutually exclusive. The order of precedence is `CPUCount` first, then `CPUShares`, and `CPUPercent` last.
   489          type: "integer"
   490          format: "int64"
   491        IOMaximumIOps:
   492          description: "Maximum IOps for the container system drive (Windows only)"
   493          type: "integer"
   494          format: "int64"
   495        IOMaximumBandwidth:
   496          description: "Maximum IO in bytes per second for the container system drive (Windows only)"
   497          type: "integer"
   498          format: "int64"
   499  
   500    ResourceObject:
   501      description: "An object describing the resources which can be advertised by a node and requested by a task"
   502      type: "object"
   503      properties:
   504        NanoCPUs:
   505          type: "integer"
   506          format: "int64"
   507          example: 4000000000
   508        MemoryBytes:
   509          type: "integer"
   510          format: "int64"
   511          example: 8272408576
   512        GenericResources:
   513          $ref: "#/definitions/GenericResources"
   514  
   515    GenericResources:
   516      description: "User-defined resources can be either Integer resources (e.g, `SSD=3`) or String resources (e.g, `GPU=UUID1`)"
   517      type: "array"
   518      items:
   519        type: "object"
   520        properties:
   521          NamedResourceSpec:
   522            type: "object"
   523            properties:
   524              Kind:
   525                type: "string"
   526              Value:
   527                type: "string"
   528          DiscreteResourceSpec:
   529            type: "object"
   530            properties:
   531              Kind:
   532                type: "string"
   533              Value:
   534                type: "integer"
   535                format: "int64"
   536      example:
   537        - DiscreteResourceSpec:
   538            Kind: "SSD"
   539            Value: 3
   540        - NamedResourceSpec:
   541            Kind: "GPU"
   542            Value: "UUID1"
   543        - NamedResourceSpec:
   544            Kind: "GPU"
   545            Value: "UUID2"
   546  
   547    HealthConfig:
   548      description: "A test to perform to check that the container is healthy."
   549      type: "object"
   550      properties:
   551        Test:
   552          description: |
   553            The test to perform. Possible values are:
   554  
   555            - `[]` inherit healthcheck from image or parent image
   556            - `["NONE"]` disable healthcheck
   557            - `["CMD", args...]` exec arguments directly
   558            - `["CMD-SHELL", command]` run command with system's default shell
   559          type: "array"
   560          items:
   561            type: "string"
   562        Interval:
   563          description: "The time to wait between checks in nanoseconds. It should be 0 or at least 1000000 (1 ms). 0 means inherit."
   564          type: "integer"
   565        Timeout:
   566          description: "The time to wait before considering the check to have hung. It should be 0 or at least 1000000 (1 ms). 0 means inherit."
   567          type: "integer"
   568        Retries:
   569          description: "The number of consecutive failures needed to consider a container as unhealthy. 0 means inherit."
   570          type: "integer"
   571        StartPeriod:
   572          description: "Start period for the container to initialize before starting health-retries countdown in nanoseconds. It should be 0 or at least 1000000 (1 ms). 0 means inherit."
   573          type: "integer"
   574  
   575    HostConfig:
   576      description: "Container configuration that depends on the host we are running on"
   577      allOf:
   578        - $ref: "#/definitions/Resources"
   579        - type: "object"
   580          properties:
   581            # Applicable to all platforms
   582            Binds:
   583              type: "array"
   584              description: |
   585                A list of volume bindings for this container. Each volume binding is a string in one of these forms:
   586  
   587                - `host-src:container-dest` to bind-mount a host path into the container. Both `host-src`, and `container-dest` must be an _absolute_ path.
   588                - `host-src:container-dest:ro` to make the bind mount read-only inside the container. Both `host-src`, and `container-dest` must be an _absolute_ path.
   589                - `volume-name:container-dest` to bind-mount a volume managed by a volume driver into the container. `container-dest` must be an _absolute_ path.
   590                - `volume-name:container-dest:ro` to mount the volume read-only inside the container.  `container-dest` must be an _absolute_ path.
   591              items:
   592                type: "string"
   593            ContainerIDFile:
   594              type: "string"
   595              description: "Path to a file where the container ID is written"
   596            LogConfig:
   597              type: "object"
   598              description: "The logging configuration for this container"
   599              properties:
   600                Type:
   601                  type: "string"
   602                  enum:
   603                    - "json-file"
   604                    - "syslog"
   605                    - "journald"
   606                    - "gelf"
   607                    - "fluentd"
   608                    - "awslogs"
   609                    - "splunk"
   610                    - "etwlogs"
   611                    - "none"
   612                Config:
   613                  type: "object"
   614                  additionalProperties:
   615                    type: "string"
   616            NetworkMode:
   617              type: "string"
   618              description: "Network mode to use for this container. Supported standard values are: `bridge`, `host`, `none`, and `container:<name|id>`. Any other value is taken
   619                as a custom network's name to which this container should connect to."
   620            PortBindings:
   621              type: "object"
   622              description: "A map of exposed container ports and the host port they should map to."
   623              additionalProperties:
   624                type: "object"
   625                properties:
   626                  HostIp:
   627                    type: "string"
   628                    description: "The host IP address"
   629                  HostPort:
   630                    type: "string"
   631                    description: "The host port number, as a string"
   632            RestartPolicy:
   633              $ref: "#/definitions/RestartPolicy"
   634            AutoRemove:
   635              type: "boolean"
   636              description: "Automatically remove the container when the container's process exits. This has no effect if `RestartPolicy` is set."
   637            VolumeDriver:
   638              type: "string"
   639              description: "Driver that this container uses to mount volumes."
   640            VolumesFrom:
   641              type: "array"
   642              description: "A list of volumes to inherit from another container, specified in the form `<container name>[:<ro|rw>]`."
   643              items:
   644                type: "string"
   645            Mounts:
   646              description: "Specification for mounts to be added to the container."
   647              type: "array"
   648              items:
   649                $ref: "#/definitions/Mount"
   650  
   651            # Applicable to UNIX platforms
   652            CapAdd:
   653              type: "array"
   654              description: "A list of kernel capabilities to add to the container."
   655              items:
   656                type: "string"
   657            CapDrop:
   658              type: "array"
   659              description: "A list of kernel capabilities to drop from the container."
   660              items:
   661                type: "string"
   662            Dns:
   663              type: "array"
   664              description: "A list of DNS servers for the container to use."
   665              items:
   666                type: "string"
   667            DnsOptions:
   668              type: "array"
   669              description: "A list of DNS options."
   670              items:
   671                type: "string"
   672            DnsSearch:
   673              type: "array"
   674              description: "A list of DNS search domains."
   675              items:
   676                type: "string"
   677            ExtraHosts:
   678              type: "array"
   679              description: |
   680                A list of hostnames/IP mappings to add to the container's `/etc/hosts` file. Specified in the form `["hostname:IP"]`.
   681              items:
   682                type: "string"
   683            GroupAdd:
   684              type: "array"
   685              description: "A list of additional groups that the container process will run as."
   686              items:
   687                type: "string"
   688            IpcMode:
   689              type: "string"
   690              description: |
   691                      IPC sharing mode for the container. Possible values are:
   692  
   693                      - `"none"`: own private IPC namespace, with /dev/shm not mounted
   694                      - `"private"`: own private IPC namespace
   695                      - `"shareable"`: own private IPC namespace, with a possibility to share it with other containers
   696                      - `"container:<name|id>"`: join another (shareable) container's IPC namespace
   697                      - `"host"`: use the host system's IPC namespace
   698  
   699                      If not specified, daemon default is used, which can either be `"private"`
   700                      or `"shareable"`, depending on daemon version and configuration.
   701            Cgroup:
   702              type: "string"
   703              description: "Cgroup to use for the container."
   704            Links:
   705              type: "array"
   706              description: "A list of links for the container in the form `container_name:alias`."
   707              items:
   708                type: "string"
   709            OomScoreAdj:
   710              type: "integer"
   711              description: "An integer value containing the score given to the container in order to tune OOM killer preferences."
   712              example: 500
   713            PidMode:
   714              type: "string"
   715              description: |
   716                Set the PID (Process) Namespace mode for the container. It can be either:
   717  
   718                - `"container:<name|id>"`: joins another container's PID namespace
   719                - `"host"`: use the host's PID namespace inside the container
   720            Privileged:
   721              type: "boolean"
   722              description: "Gives the container full access to the host."
   723            PublishAllPorts:
   724              type: "boolean"
   725              description: |
   726                Allocates an ephemeral host port for all of a container's
   727                exposed ports.
   728  
   729                Ports are de-allocated when the container stops and allocated when the container starts.
   730                The allocated port might be changed when restarting the container.
   731  
   732                The port is selected from the ephemeral port range that depends on the kernel.
   733                For example, on Linux the range is defined by `/proc/sys/net/ipv4/ip_local_port_range`.
   734            ReadonlyRootfs:
   735              type: "boolean"
   736              description: "Mount the container's root filesystem as read only."
   737            SecurityOpt:
   738              type: "array"
   739              description: "A list of string values to customize labels for MLS
   740              systems, such as SELinux."
   741              items:
   742                type: "string"
   743            StorageOpt:
   744              type: "object"
   745              description: |
   746                Storage driver options for this container, in the form `{"size": "120G"}`.
   747              additionalProperties:
   748                type: "string"
   749            Tmpfs:
   750              type: "object"
   751              description: |
   752                A map of container directories which should be replaced by tmpfs mounts, and their corresponding mount options. For example: `{ "/run": "rw,noexec,nosuid,size=65536k" }`.
   753              additionalProperties:
   754                type: "string"
   755            UTSMode:
   756              type: "string"
   757              description: "UTS namespace to use for the container."
   758            UsernsMode:
   759              type: "string"
   760              description: "Sets the usernamespace mode for the container when usernamespace remapping option is enabled."
   761            ShmSize:
   762              type: "integer"
   763              description: "Size of `/dev/shm` in bytes. If omitted, the system uses 64MB."
   764              minimum: 0
   765            Sysctls:
   766              type: "object"
   767              description: |
   768                A list of kernel parameters (sysctls) to set in the container. For example: `{"net.ipv4.ip_forward": "1"}`
   769              additionalProperties:
   770                type: "string"
   771            Runtime:
   772              type: "string"
   773              description: "Runtime to use with this container."
   774            # Applicable to Windows
   775            ConsoleSize:
   776              type: "array"
   777              description: "Initial console size, as an `[height, width]` array. (Windows only)"
   778              minItems: 2
   779              maxItems: 2
   780              items:
   781                type: "integer"
   782                minimum: 0
   783            Isolation:
   784              type: "string"
   785              description: "Isolation technology of the container. (Windows only)"
   786              enum:
   787                - "default"
   788                - "process"
   789                - "hyperv"
   790  
   791    ContainerConfig:
   792      description: "Configuration for a container that is portable between hosts"
   793      type: "object"
   794      properties:
   795        Hostname:
   796          description: "The hostname to use for the container, as a valid RFC 1123 hostname."
   797          type: "string"
   798        Domainname:
   799          description: "The domain name to use for the container."
   800          type: "string"
   801        User:
   802          description: "The user that commands are run as inside the container."
   803          type: "string"
   804        AttachStdin:
   805          description: "Whether to attach to `stdin`."
   806          type: "boolean"
   807          default: false
   808        AttachStdout:
   809          description: "Whether to attach to `stdout`."
   810          type: "boolean"
   811          default: true
   812        AttachStderr:
   813          description: "Whether to attach to `stderr`."
   814          type: "boolean"
   815          default: true
   816        ExposedPorts:
   817          description: |
   818            An object mapping ports to an empty object in the form:
   819  
   820            `{"<port>/<tcp|udp>": {}}`
   821          type: "object"
   822          additionalProperties:
   823            type: "object"
   824            enum:
   825              - {}
   826            default: {}
   827        Tty:
   828          description: "Attach standard streams to a TTY, including `stdin` if it is not closed."
   829          type: "boolean"
   830          default: false
   831        OpenStdin:
   832          description: "Open `stdin`"
   833          type: "boolean"
   834          default: false
   835        StdinOnce:
   836          description: "Close `stdin` after one attached client disconnects"
   837          type: "boolean"
   838          default: false
   839        Env:
   840          description: |
   841            A list of environment variables to set inside the container in the form `["VAR=value", ...]`. A variable without `=` is removed from the environment, rather than to have an empty value.
   842          type: "array"
   843          items:
   844            type: "string"
   845        Cmd:
   846          description: "Command to run specified as a string or an array of strings."
   847          type:
   848            - "array"
   849            - "string"
   850          items:
   851            type: "string"
   852        Healthcheck:
   853          $ref: "#/definitions/HealthConfig"
   854        ArgsEscaped:
   855          description: "Command is already escaped (Windows only)"
   856          type: "boolean"
   857        Image:
   858          description: "The name of the image to use when creating the container"
   859          type: "string"
   860        Volumes:
   861          description: "An object mapping mount point paths inside the container to empty objects."
   862          type: "object"
   863          properties:
   864            additionalProperties:
   865              type: "object"
   866              enum:
   867                - {}
   868              default: {}
   869        WorkingDir:
   870          description: "The working directory for commands to run in."
   871          type: "string"
   872        Entrypoint:
   873          description: |
   874            The entry point for the container as a string or an array of strings.
   875  
   876            If the array consists of exactly one empty string (`[""]`) then the entry point is reset to system default (i.e., the entry point used by docker when there is no `ENTRYPOINT` instruction in the `Dockerfile`).
   877          type:
   878            - "array"
   879            - "string"
   880          items:
   881            type: "string"
   882        NetworkDisabled:
   883          description: "Disable networking for the container."
   884          type: "boolean"
   885        MacAddress:
   886          description: "MAC address of the container."
   887          type: "string"
   888        OnBuild:
   889          description: "`ONBUILD` metadata that were defined in the image's `Dockerfile`."
   890          type: "array"
   891          items:
   892            type: "string"
   893        Labels:
   894          description: "User-defined key/value metadata."
   895          type: "object"
   896          additionalProperties:
   897            type: "string"
   898        StopSignal:
   899          description: "Signal to stop a container as a string or unsigned integer."
   900          type: "string"
   901          default: "SIGTERM"
   902        StopTimeout:
   903          description: "Timeout to stop a container in seconds."
   904          type: "integer"
   905          default: 10
   906        Shell:
   907          description: "Shell for when `RUN`, `CMD`, and `ENTRYPOINT` uses a shell."
   908          type: "array"
   909          items:
   910            type: "string"
   911  
   912    NetworkSettings:
   913      description: "NetworkSettings exposes the network settings in the API"
   914      type: "object"
   915      properties:
   916        Bridge:
   917          description: Name of the network'a bridge (for example, `docker0`).
   918          type: "string"
   919          example: "docker0"
   920        SandboxID:
   921          description: SandboxID uniquely represents a container's network stack.
   922          type: "string"
   923          example: "9d12daf2c33f5959c8bf90aa513e4f65b561738661003029ec84830cd503a0c3"
   924        HairpinMode:
   925          description: |
   926            Indicates if hairpin NAT should be enabled on the virtual interface.
   927          type: "boolean"
   928          example: false
   929        LinkLocalIPv6Address:
   930          description: IPv6 unicast address using the link-local prefix.
   931          type: "string"
   932          example: "fe80::42:acff:fe11:1"
   933        LinkLocalIPv6PrefixLen:
   934          description: Prefix length of the IPv6 unicast address.
   935          type: "integer"
   936          example: "64"
   937        Ports:
   938          $ref: "#/definitions/PortMap"
   939        SandboxKey:
   940          description: SandboxKey identifies the sandbox
   941          type: "string"
   942          example: "/var/run/docker/netns/8ab54b426c38"
   943  
   944        # TODO is SecondaryIPAddresses actually used?
   945        SecondaryIPAddresses:
   946          description: ""
   947          type: "array"
   948          items:
   949            $ref: "#/definitions/Address"
   950          x-nullable: true
   951  
   952        # TODO is SecondaryIPv6Addresses actually used?
   953        SecondaryIPv6Addresses:
   954          description: ""
   955          type: "array"
   956          items:
   957            $ref: "#/definitions/Address"
   958          x-nullable: true
   959  
   960        # TODO properties below are part of DefaultNetworkSettings, which is
   961        # marked as deprecated since Docker 1.9 and to be removed in Docker v17.12
   962        EndpointID:
   963          description: |
   964            EndpointID uniquely represents a service endpoint in a Sandbox.
   965  
   966            <p><br /></p>
   967  
   968            > **Deprecated**: This field is only propagated when attached to the
   969            > default "bridge" network. Use the information from the "bridge"
   970            > network inside the `Networks` map instead, which contains the same
   971            > information. This field was deprecated in Docker 1.9 and is scheduled
   972            > to be removed in Docker 17.12.0
   973          type: "string"
   974          example: "b88f5b905aabf2893f3cbc4ee42d1ea7980bbc0a92e2c8922b1e1795298afb0b"
   975        Gateway:
   976          description: |
   977            Gateway address for the default "bridge" network.
   978  
   979            <p><br /></p>
   980  
   981            > **Deprecated**: This field is only propagated when attached to the
   982            > default "bridge" network. Use the information from the "bridge"
   983            > network inside the `Networks` map instead, which contains the same
   984            > information. This field was deprecated in Docker 1.9 and is scheduled
   985            > to be removed in Docker 17.12.0
   986          type: "string"
   987          example: "172.17.0.1"
   988        GlobalIPv6Address:
   989          description: |
   990            Global IPv6 address for the default "bridge" network.
   991  
   992            <p><br /></p>
   993  
   994            > **Deprecated**: This field is only propagated when attached to the
   995            > default "bridge" network. Use the information from the "bridge"
   996            > network inside the `Networks` map instead, which contains the same
   997            > information. This field was deprecated in Docker 1.9 and is scheduled
   998            > to be removed in Docker 17.12.0
   999          type: "string"
  1000          example: "2001:db8::5689"
  1001        GlobalIPv6PrefixLen:
  1002          description: |
  1003            Mask length of the global IPv6 address.
  1004  
  1005            <p><br /></p>
  1006  
  1007            > **Deprecated**: This field is only propagated when attached to the
  1008            > default "bridge" network. Use the information from the "bridge"
  1009            > network inside the `Networks` map instead, which contains the same
  1010            > information. This field was deprecated in Docker 1.9 and is scheduled
  1011            > to be removed in Docker 17.12.0
  1012          type: "integer"
  1013          example: 64
  1014        IPAddress:
  1015          description: |
  1016            IPv4 address for the default "bridge" network.
  1017  
  1018            <p><br /></p>
  1019  
  1020            > **Deprecated**: This field is only propagated when attached to the
  1021            > default "bridge" network. Use the information from the "bridge"
  1022            > network inside the `Networks` map instead, which contains the same
  1023            > information. This field was deprecated in Docker 1.9 and is scheduled
  1024            > to be removed in Docker 17.12.0
  1025          type: "string"
  1026          example: "172.17.0.4"
  1027        IPPrefixLen:
  1028          description: |
  1029            Mask length of the IPv4 address.
  1030  
  1031            <p><br /></p>
  1032  
  1033            > **Deprecated**: This field is only propagated when attached to the
  1034            > default "bridge" network. Use the information from the "bridge"
  1035            > network inside the `Networks` map instead, which contains the same
  1036            > information. This field was deprecated in Docker 1.9 and is scheduled
  1037            > to be removed in Docker 17.12.0
  1038          type: "integer"
  1039          example: 16
  1040        IPv6Gateway:
  1041          description: |
  1042            IPv6 gateway address for this network.
  1043  
  1044            <p><br /></p>
  1045  
  1046            > **Deprecated**: This field is only propagated when attached to the
  1047            > default "bridge" network. Use the information from the "bridge"
  1048            > network inside the `Networks` map instead, which contains the same
  1049            > information. This field was deprecated in Docker 1.9 and is scheduled
  1050            > to be removed in Docker 17.12.0
  1051          type: "string"
  1052          example: "2001:db8:2::100"
  1053        MacAddress:
  1054          description: |
  1055            MAC address for the container on the default "bridge" network.
  1056  
  1057            <p><br /></p>
  1058  
  1059            > **Deprecated**: This field is only propagated when attached to the
  1060            > default "bridge" network. Use the information from the "bridge"
  1061            > network inside the `Networks` map instead, which contains the same
  1062            > information. This field was deprecated in Docker 1.9 and is scheduled
  1063            > to be removed in Docker 17.12.0
  1064          type: "string"
  1065          example: "02:42:ac:11:00:04"
  1066        Networks:
  1067          description: |
  1068            Information about all networks that the container is connected to.
  1069          type: "object"
  1070          additionalProperties:
  1071            $ref: "#/definitions/EndpointSettings"
  1072  
  1073    Address:
  1074      description: Address represents an IPv4 or IPv6 IP address.
  1075      type: "object"
  1076      properties:
  1077        Addr:
  1078          description: IP address.
  1079          type: "string"
  1080        PrefixLen:
  1081          description: Mask length of the IP address.
  1082          type: "integer"
  1083  
  1084    PortMap:
  1085      description: |
  1086        PortMap describes the mapping of container ports to host ports, using the
  1087        container's port-number and protocol as key in the format `<port>/<protocol>`,
  1088        for example, `80/udp`.
  1089  
  1090        If a container's port is mapped for both `tcp` and `udp`, two separate
  1091        entries are added to the mapping table.
  1092      type: "object"
  1093      additionalProperties:
  1094        type: "array"
  1095        items:
  1096          $ref: "#/definitions/PortBinding"
  1097      example:
  1098        "443/tcp":
  1099          - HostIp: "127.0.0.1"
  1100            HostPort: "4443"
  1101        "80/tcp":
  1102          - HostIp: "0.0.0.0"
  1103            HostPort: "80"
  1104          - HostIp: "0.0.0.0"
  1105            HostPort: "8080"
  1106        "80/udp":
  1107          - HostIp: "0.0.0.0"
  1108            HostPort: "80"
  1109        "53/udp":
  1110          - HostIp: "0.0.0.0"
  1111            HostPort: "53"
  1112        "2377/tcp": null
  1113  
  1114    PortBinding:
  1115      description: |
  1116        PortBinding represents a binding between a host IP address and a host
  1117        port.
  1118      type: "object"
  1119      x-nullable: true
  1120      properties:
  1121        HostIp:
  1122          description: "Host IP address that the container's port is mapped to."
  1123          type: "string"
  1124          example: "127.0.0.1"
  1125        HostPort:
  1126          description: "Host port number that the container's port is mapped to."
  1127          type: "string"
  1128          example: "4443"
  1129  
  1130    GraphDriverData:
  1131      description: "Information about a container's graph driver."
  1132      type: "object"
  1133      required: [Name, Data]
  1134      properties:
  1135        Name:
  1136          type: "string"
  1137          x-nullable: false
  1138        Data:
  1139          type: "object"
  1140          x-nullable: false
  1141          additionalProperties:
  1142            type: "string"
  1143  
  1144    Image:
  1145      type: "object"
  1146      required:
  1147        - Id
  1148        - Parent
  1149        - Comment
  1150        - Created
  1151        - Container
  1152        - DockerVersion
  1153        - Author
  1154        - Architecture
  1155        - Os
  1156        - Size
  1157        - VirtualSize
  1158        - GraphDriver
  1159        - RootFS
  1160      properties:
  1161        Id:
  1162          type: "string"
  1163          x-nullable: false
  1164        RepoTags:
  1165          type: "array"
  1166          items:
  1167            type: "string"
  1168        RepoDigests:
  1169          type: "array"
  1170          items:
  1171            type: "string"
  1172        Parent:
  1173          type: "string"
  1174          x-nullable: false
  1175        Comment:
  1176          type: "string"
  1177          x-nullable: false
  1178        Created:
  1179          type: "string"
  1180          x-nullable: false
  1181        Container:
  1182          type: "string"
  1183          x-nullable: false
  1184        ContainerConfig:
  1185          $ref: "#/definitions/ContainerConfig"
  1186        DockerVersion:
  1187          type: "string"
  1188          x-nullable: false
  1189        Author:
  1190          type: "string"
  1191          x-nullable: false
  1192        Config:
  1193          $ref: "#/definitions/ContainerConfig"
  1194        Architecture:
  1195          type: "string"
  1196          x-nullable: false
  1197        Os:
  1198          type: "string"
  1199          x-nullable: false
  1200        OsVersion:
  1201          type: "string"
  1202        Size:
  1203          type: "integer"
  1204          format: "int64"
  1205          x-nullable: false
  1206        VirtualSize:
  1207          type: "integer"
  1208          format: "int64"
  1209          x-nullable: false
  1210        GraphDriver:
  1211          $ref: "#/definitions/GraphDriverData"
  1212        RootFS:
  1213          type: "object"
  1214          required: [Type]
  1215          properties:
  1216            Type:
  1217              type: "string"
  1218              x-nullable: false
  1219            Layers:
  1220              type: "array"
  1221              items:
  1222                type: "string"
  1223            BaseLayer:
  1224              type: "string"
  1225        Metadata:
  1226          type: "object"
  1227          properties:
  1228            LastTagTime:
  1229              type: "string"
  1230              format: "dateTime"
  1231  
  1232    ImageSummary:
  1233      type: "object"
  1234      required:
  1235        - Id
  1236        - ParentId
  1237        - RepoTags
  1238        - RepoDigests
  1239        - Created
  1240        - Size
  1241        - SharedSize
  1242        - VirtualSize
  1243        - Labels
  1244        - Containers
  1245      properties:
  1246        Id:
  1247          type: "string"
  1248          x-nullable: false
  1249        ParentId:
  1250          type: "string"
  1251          x-nullable: false
  1252        RepoTags:
  1253          type: "array"
  1254          x-nullable: false
  1255          items:
  1256            type: "string"
  1257        RepoDigests:
  1258          type: "array"
  1259          x-nullable: false
  1260          items:
  1261            type: "string"
  1262        Created:
  1263          type: "integer"
  1264          x-nullable: false
  1265        Size:
  1266          type: "integer"
  1267          x-nullable: false
  1268        SharedSize:
  1269          type: "integer"
  1270          x-nullable: false
  1271        VirtualSize:
  1272          type: "integer"
  1273          x-nullable: false
  1274        Labels:
  1275          type: "object"
  1276          x-nullable: false
  1277          additionalProperties:
  1278            type: "string"
  1279        Containers:
  1280          x-nullable: false
  1281          type: "integer"
  1282  
  1283    AuthConfig:
  1284      type: "object"
  1285      properties:
  1286        username:
  1287          type: "string"
  1288        password:
  1289          type: "string"
  1290        email:
  1291          type: "string"
  1292        serveraddress:
  1293          type: "string"
  1294      example:
  1295        username: "hannibal"
  1296        password: "xxxx"
  1297        serveraddress: "https://index.docker.io/v1/"
  1298  
  1299    ProcessConfig:
  1300      type: "object"
  1301      properties:
  1302        privileged:
  1303          type: "boolean"
  1304        user:
  1305          type: "string"
  1306        tty:
  1307          type: "boolean"
  1308        entrypoint:
  1309          type: "string"
  1310        arguments:
  1311          type: "array"
  1312          items:
  1313            type: "string"
  1314  
  1315    Volume:
  1316      type: "object"
  1317      required: [Name, Driver, Mountpoint, Labels, Scope, Options]
  1318      properties:
  1319        Name:
  1320          type: "string"
  1321          description: "Name of the volume."
  1322          x-nullable: false
  1323        Driver:
  1324          type: "string"
  1325          description: "Name of the volume driver used by the volume."
  1326          x-nullable: false
  1327        Mountpoint:
  1328          type: "string"
  1329          description: "Mount path of the volume on the host."
  1330          x-nullable: false
  1331        CreatedAt:
  1332          type: "string"
  1333          format: "dateTime"
  1334          description: "Date/Time the volume was created."
  1335        Status:
  1336          type: "object"
  1337          description: |
  1338            Low-level details about the volume, provided by the volume driver.
  1339            Details are returned as a map with key/value pairs:
  1340            `{"key":"value","key2":"value2"}`.
  1341  
  1342            The `Status` field is optional, and is omitted if the volume driver
  1343            does not support this feature.
  1344          additionalProperties:
  1345            type: "object"
  1346        Labels:
  1347          type: "object"
  1348          description: "User-defined key/value metadata."
  1349          x-nullable: false
  1350          additionalProperties:
  1351            type: "string"
  1352        Scope:
  1353          type: "string"
  1354          description: "The level at which the volume exists. Either `global` for cluster-wide, or `local` for machine level."
  1355          default: "local"
  1356          x-nullable: false
  1357          enum: ["local", "global"]
  1358        Options:
  1359          type: "object"
  1360          description: "The driver specific options used when creating the volume."
  1361          additionalProperties:
  1362            type: "string"
  1363        UsageData:
  1364          type: "object"
  1365          x-nullable: true
  1366          required: [Size, RefCount]
  1367          description: |
  1368            Usage details about the volume. This information is used by the
  1369            `GET /system/df` endpoint, and omitted in other endpoints.
  1370          properties:
  1371            Size:
  1372              type: "integer"
  1373              default: -1
  1374              description: |
  1375                Amount of disk space used by the volume (in bytes). This information
  1376                is only available for volumes created with the `"local"` volume
  1377                driver. For volumes created with other volume drivers, this field
  1378                is set to `-1` ("not available")
  1379              x-nullable: false
  1380            RefCount:
  1381              type: "integer"
  1382              default: -1
  1383              description: |
  1384                The number of containers referencing this volume. This field
  1385                is set to `-1` if the reference-count is not available.
  1386              x-nullable: false
  1387  
  1388      example:
  1389        Name: "tardis"
  1390        Driver: "custom"
  1391        Mountpoint: "/var/lib/docker/volumes/tardis"
  1392        Status:
  1393          hello: "world"
  1394        Labels:
  1395          com.example.some-label: "some-value"
  1396          com.example.some-other-label: "some-other-value"
  1397        Scope: "local"
  1398        CreatedAt: "2016-06-07T20:31:11.853781916Z"
  1399  
  1400    Network:
  1401      type: "object"
  1402      properties:
  1403        Name:
  1404          type: "string"
  1405        Id:
  1406          type: "string"
  1407        Created:
  1408          type: "string"
  1409          format: "dateTime"
  1410        Scope:
  1411          type: "string"
  1412        Driver:
  1413          type: "string"
  1414        EnableIPv6:
  1415          type: "boolean"
  1416        IPAM:
  1417          $ref: "#/definitions/IPAM"
  1418        Internal:
  1419          type: "boolean"
  1420        Attachable:
  1421          type: "boolean"
  1422        Ingress:
  1423          type: "boolean"
  1424        Containers:
  1425          type: "object"
  1426          additionalProperties:
  1427            $ref: "#/definitions/NetworkContainer"
  1428        Options:
  1429          type: "object"
  1430          additionalProperties:
  1431            type: "string"
  1432        Labels:
  1433          type: "object"
  1434          additionalProperties:
  1435            type: "string"
  1436      example:
  1437        Name: "net01"
  1438        Id: "7d86d31b1478e7cca9ebed7e73aa0fdeec46c5ca29497431d3007d2d9e15ed99"
  1439        Created: "2016-10-19T04:33:30.360899459Z"
  1440        Scope: "local"
  1441        Driver: "bridge"
  1442        EnableIPv6: false
  1443        IPAM:
  1444          Driver: "default"
  1445          Config:
  1446            - Subnet: "172.19.0.0/16"
  1447              Gateway: "172.19.0.1"
  1448          Options:
  1449            foo: "bar"
  1450        Internal: false
  1451        Attachable: false
  1452        Ingress: false
  1453        Containers:
  1454          19a4d5d687db25203351ed79d478946f861258f018fe384f229f2efa4b23513c:
  1455            Name: "test"
  1456            EndpointID: "628cadb8bcb92de107b2a1e516cbffe463e321f548feb37697cce00ad694f21a"
  1457            MacAddress: "02:42:ac:13:00:02"
  1458            IPv4Address: "172.19.0.2/16"
  1459            IPv6Address: ""
  1460        Options:
  1461          com.docker.network.bridge.default_bridge: "true"
  1462          com.docker.network.bridge.enable_icc: "true"
  1463          com.docker.network.bridge.enable_ip_masquerade: "true"
  1464          com.docker.network.bridge.host_binding_ipv4: "0.0.0.0"
  1465          com.docker.network.bridge.name: "docker0"
  1466          com.docker.network.driver.mtu: "1500"
  1467        Labels:
  1468          com.example.some-label: "some-value"
  1469          com.example.some-other-label: "some-other-value"
  1470    IPAM:
  1471      type: "object"
  1472      properties:
  1473        Driver:
  1474          description: "Name of the IPAM driver to use."
  1475          type: "string"
  1476          default: "default"
  1477        Config:
  1478          description: "List of IPAM configuration options, specified as a map: `{\"Subnet\": <CIDR>, \"IPRange\": <CIDR>, \"Gateway\": <IP address>, \"AuxAddress\": <device_name:IP address>}`"
  1479          type: "array"
  1480          items:
  1481            type: "object"
  1482            additionalProperties:
  1483              type: "string"
  1484        Options:
  1485          description: "Driver-specific options, specified as a map."
  1486          type: "array"
  1487          items:
  1488            type: "object"
  1489            additionalProperties:
  1490              type: "string"
  1491  
  1492    NetworkContainer:
  1493      type: "object"
  1494      properties:
  1495        Name:
  1496          type: "string"
  1497        EndpointID:
  1498          type: "string"
  1499        MacAddress:
  1500          type: "string"
  1501        IPv4Address:
  1502          type: "string"
  1503        IPv6Address:
  1504          type: "string"
  1505  
  1506    BuildInfo:
  1507      type: "object"
  1508      properties:
  1509        id:
  1510          type: "string"
  1511        stream:
  1512          type: "string"
  1513        error:
  1514          type: "string"
  1515        errorDetail:
  1516          $ref: "#/definitions/ErrorDetail"
  1517        status:
  1518          type: "string"
  1519        progress:
  1520          type: "string"
  1521        progressDetail:
  1522          $ref: "#/definitions/ProgressDetail"
  1523  
  1524    CreateImageInfo:
  1525      type: "object"
  1526      properties:
  1527        error:
  1528          type: "string"
  1529        status:
  1530          type: "string"
  1531        progress:
  1532          type: "string"
  1533        progressDetail:
  1534          $ref: "#/definitions/ProgressDetail"
  1535  
  1536    PushImageInfo:
  1537      type: "object"
  1538      properties:
  1539        error:
  1540          type: "string"
  1541        status:
  1542          type: "string"
  1543        progress:
  1544          type: "string"
  1545        progressDetail:
  1546          $ref: "#/definitions/ProgressDetail"
  1547  
  1548    ErrorDetail:
  1549      type: "object"
  1550      properties:
  1551        code:
  1552          type: "integer"
  1553        message:
  1554          type: "string"
  1555  
  1556    ProgressDetail:
  1557      type: "object"
  1558      properties:
  1559        code:
  1560          type: "integer"
  1561        message:
  1562          type: "integer"
  1563  
  1564    ErrorResponse:
  1565      description: "Represents an error."
  1566      type: "object"
  1567      required: ["message"]
  1568      properties:
  1569        message:
  1570          description: "The error message."
  1571          type: "string"
  1572          x-nullable: false
  1573      example:
  1574        message: "Something went wrong."
  1575  
  1576    IdResponse:
  1577      description: "Response to an API call that returns just an Id"
  1578      type: "object"
  1579      required: ["Id"]
  1580      properties:
  1581        Id:
  1582          description: "The id of the newly created object."
  1583          type: "string"
  1584          x-nullable: false
  1585  
  1586    EndpointSettings:
  1587      description: "Configuration for a network endpoint."
  1588      type: "object"
  1589      properties:
  1590        # Configurations
  1591        IPAMConfig:
  1592          $ref: "#/definitions/EndpointIPAMConfig"
  1593        Links:
  1594          type: "array"
  1595          items:
  1596            type: "string"
  1597          example:
  1598            - "container_1"
  1599            - "container_2"
  1600        Aliases:
  1601          type: "array"
  1602          items:
  1603            type: "string"
  1604          example:
  1605            - "server_x"
  1606            - "server_y"
  1607  
  1608        # Operational data
  1609        NetworkID:
  1610          description: |
  1611            Unique ID of the network.
  1612          type: "string"
  1613          example: "08754567f1f40222263eab4102e1c733ae697e8e354aa9cd6e18d7402835292a"
  1614        EndpointID:
  1615          description: |
  1616            Unique ID for the service endpoint in a Sandbox.
  1617          type: "string"
  1618          example: "b88f5b905aabf2893f3cbc4ee42d1ea7980bbc0a92e2c8922b1e1795298afb0b"
  1619        Gateway:
  1620          description: |
  1621            Gateway address for this network.
  1622          type: "string"
  1623          example: "172.17.0.1"
  1624        IPAddress:
  1625          description: |
  1626            IPv4 address.
  1627          type: "string"
  1628          example: "172.17.0.4"
  1629        IPPrefixLen:
  1630          description: |
  1631            Mask length of the IPv4 address.
  1632          type: "integer"
  1633          example: 16
  1634        IPv6Gateway:
  1635          description: |
  1636            IPv6 gateway address.
  1637          type: "string"
  1638          example: "2001:db8:2::100"
  1639        GlobalIPv6Address:
  1640          description: |
  1641            Global IPv6 address.
  1642          type: "string"
  1643          example: "2001:db8::5689"
  1644        GlobalIPv6PrefixLen:
  1645          description: |
  1646            Mask length of the global IPv6 address.
  1647          type: "integer"
  1648          format: "int64"
  1649          example: 64
  1650        MacAddress:
  1651          description: |
  1652            MAC address for the endpoint on this network.
  1653          type: "string"
  1654          example: "02:42:ac:11:00:04"
  1655        DriverOpts:
  1656          description: |
  1657            DriverOpts is a mapping of driver options and values. These options
  1658            are passed directly to the driver and are driver specific.
  1659          type: "object"
  1660          x-nullable: true
  1661          additionalProperties:
  1662            type: "string"
  1663          example:
  1664            com.example.some-label: "some-value"
  1665            com.example.some-other-label: "some-other-value"
  1666  
  1667    EndpointIPAMConfig:
  1668      description: |
  1669        EndpointIPAMConfig represents an endpoint's IPAM configuration.
  1670      type: "object"
  1671      x-nullable: true
  1672      properties:
  1673        IPv4Address:
  1674          type: "string"
  1675          example: "172.20.30.33"
  1676        IPv6Address:
  1677          type: "string"
  1678          example: "2001:db8:abcd::3033"
  1679        LinkLocalIPs:
  1680          type: "array"
  1681          items:
  1682            type: "string"
  1683          example:
  1684            - "169.254.34.68"
  1685            - "fe80::3468"
  1686  
  1687    PluginMount:
  1688      type: "object"
  1689      x-nullable: false
  1690      required: [Name, Description, Settable, Source, Destination, Type, Options]
  1691      properties:
  1692        Name:
  1693          type: "string"
  1694          x-nullable: false
  1695          example: "some-mount"
  1696        Description:
  1697          type: "string"
  1698          x-nullable: false
  1699          example: "This is a mount that's used by the plugin."
  1700        Settable:
  1701          type: "array"
  1702          items:
  1703            type: "string"
  1704        Source:
  1705          type: "string"
  1706          example: "/var/lib/docker/plugins/"
  1707        Destination:
  1708          type: "string"
  1709          x-nullable: false
  1710          example: "/mnt/state"
  1711        Type:
  1712          type: "string"
  1713          x-nullable: false
  1714          example: "bind"
  1715        Options:
  1716          type: "array"
  1717          items:
  1718            type: "string"
  1719          example:
  1720            - "rbind"
  1721            - "rw"
  1722  
  1723    PluginDevice:
  1724      type: "object"
  1725      required: [Name, Description, Settable, Path]
  1726      x-nullable: false
  1727      properties:
  1728        Name:
  1729          type: "string"
  1730          x-nullable: false
  1731        Description:
  1732          type: "string"
  1733          x-nullable: false
  1734        Settable:
  1735          type: "array"
  1736          items:
  1737            type: "string"
  1738        Path:
  1739          type: "string"
  1740          example: "/dev/fuse"
  1741  
  1742    PluginEnv:
  1743      type: "object"
  1744      x-nullable: false
  1745      required: [Name, Description, Settable, Value]
  1746      properties:
  1747        Name:
  1748          x-nullable: false
  1749          type: "string"
  1750        Description:
  1751          x-nullable: false
  1752          type: "string"
  1753        Settable:
  1754          type: "array"
  1755          items:
  1756            type: "string"
  1757        Value:
  1758          type: "string"
  1759  
  1760    PluginInterfaceType:
  1761      type: "object"
  1762      x-nullable: false
  1763      required: [Prefix, Capability, Version]
  1764      properties:
  1765        Prefix:
  1766          type: "string"
  1767          x-nullable: false
  1768        Capability:
  1769          type: "string"
  1770          x-nullable: false
  1771        Version:
  1772          type: "string"
  1773          x-nullable: false
  1774  
  1775    Plugin:
  1776      description: "A plugin for the Engine API"
  1777      type: "object"
  1778      required: [Settings, Enabled, Config, Name]
  1779      properties:
  1780        Id:
  1781          type: "string"
  1782          example: "5724e2c8652da337ab2eedd19fc6fc0ec908e4bd907c7421bf6a8dfc70c4c078"
  1783        Name:
  1784          type: "string"
  1785          x-nullable: false
  1786          example: "tiborvass/sample-volume-plugin"
  1787        Enabled:
  1788          description: "True if the plugin is running. False if the plugin is not running, only installed."
  1789          type: "boolean"
  1790          x-nullable: false
  1791          example: true
  1792        Settings:
  1793          description: "Settings that can be modified by users."
  1794          type: "object"
  1795          x-nullable: false
  1796          required: [Args, Devices, Env, Mounts]
  1797          properties:
  1798            Mounts:
  1799              type: "array"
  1800              items:
  1801                $ref: "#/definitions/PluginMount"
  1802            Env:
  1803              type: "array"
  1804              items:
  1805                type: "string"
  1806              example:
  1807                - "DEBUG=0"
  1808            Args:
  1809              type: "array"
  1810              items:
  1811                type: "string"
  1812            Devices:
  1813              type: "array"
  1814              items:
  1815                $ref: "#/definitions/PluginDevice"
  1816        PluginReference:
  1817          description: "plugin remote reference used to push/pull the plugin"
  1818          type: "string"
  1819          x-nullable: false
  1820          example: "localhost:5000/tiborvass/sample-volume-plugin:latest"
  1821        Config:
  1822          description: "The config of a plugin."
  1823          type: "object"
  1824          x-nullable: false
  1825          required:
  1826            - Description
  1827            - Documentation
  1828            - Interface
  1829            - Entrypoint
  1830            - WorkDir
  1831            - Network
  1832            - Linux
  1833            - PidHost
  1834            - PropagatedMount
  1835            - IpcHost
  1836            - Mounts
  1837            - Env
  1838            - Args
  1839          properties:
  1840            DockerVersion:
  1841              description: "Docker Version used to create the plugin"
  1842              type: "string"
  1843              x-nullable: false
  1844              example: "17.06.0-ce"
  1845            Description:
  1846              type: "string"
  1847              x-nullable: false
  1848              example: "A sample volume plugin for Docker"
  1849            Documentation:
  1850              type: "string"
  1851              x-nullable: false
  1852              example: "https://docs.docker.com/engine/extend/plugins/"
  1853            Interface:
  1854              description: "The interface between Docker and the plugin"
  1855              x-nullable: false
  1856              type: "object"
  1857              required: [Types, Socket]
  1858              properties:
  1859                Types:
  1860                  type: "array"
  1861                  items:
  1862                    $ref: "#/definitions/PluginInterfaceType"
  1863                  example:
  1864                    - "docker.volumedriver/1.0"
  1865                Socket:
  1866                  type: "string"
  1867                  x-nullable: false
  1868                  example: "plugins.sock"
  1869            Entrypoint:
  1870              type: "array"
  1871              items:
  1872                type: "string"
  1873              example:
  1874                - "/usr/bin/sample-volume-plugin"
  1875                - "/data"
  1876            WorkDir:
  1877              type: "string"
  1878              x-nullable: false
  1879              example: "/bin/"
  1880            User:
  1881              type: "object"
  1882              x-nullable: false
  1883              properties:
  1884                UID:
  1885                  type: "integer"
  1886                  format: "uint32"
  1887                  example: 1000
  1888                GID:
  1889                  type: "integer"
  1890                  format: "uint32"
  1891                  example: 1000
  1892            Network:
  1893              type: "object"
  1894              x-nullable: false
  1895              required: [Type]
  1896              properties:
  1897                Type:
  1898                  x-nullable: false
  1899                  type: "string"
  1900                  example: "host"
  1901            Linux:
  1902              type: "object"
  1903              x-nullable: false
  1904              required: [Capabilities, AllowAllDevices, Devices]
  1905              properties:
  1906                Capabilities:
  1907                  type: "array"
  1908                  items:
  1909                    type: "string"
  1910                  example:
  1911                    - "CAP_SYS_ADMIN"
  1912                    - "CAP_SYSLOG"
  1913                AllowAllDevices:
  1914                  type: "boolean"
  1915                  x-nullable: false
  1916                  example: false
  1917                Devices:
  1918                  type: "array"
  1919                  items:
  1920                    $ref: "#/definitions/PluginDevice"
  1921            PropagatedMount:
  1922              type: "string"
  1923              x-nullable: false
  1924              example: "/mnt/volumes"
  1925            IpcHost:
  1926              type: "boolean"
  1927              x-nullable: false
  1928              example: false
  1929            PidHost:
  1930              type: "boolean"
  1931              x-nullable: false
  1932              example: false
  1933            Mounts:
  1934              type: "array"
  1935              items:
  1936                $ref: "#/definitions/PluginMount"
  1937            Env:
  1938              type: "array"
  1939              items:
  1940                $ref: "#/definitions/PluginEnv"
  1941              example:
  1942                - Name: "DEBUG"
  1943                  Description: "If set, prints debug messages"
  1944                  Settable: null
  1945                  Value: "0"
  1946            Args:
  1947              type: "object"
  1948              x-nullable: false
  1949              required: [Name, Description, Settable, Value]
  1950              properties:
  1951                Name:
  1952                  x-nullable: false
  1953                  type: "string"
  1954                  example: "args"
  1955                Description:
  1956                  x-nullable: false
  1957                  type: "string"
  1958                  example: "command line arguments"
  1959                Settable:
  1960                  type: "array"
  1961                  items:
  1962                    type: "string"
  1963                Value:
  1964                  type: "array"
  1965                  items:
  1966                    type: "string"
  1967            rootfs:
  1968              type: "object"
  1969              properties:
  1970                type:
  1971                  type: "string"
  1972                  example: "layers"
  1973                diff_ids:
  1974                  type: "array"
  1975                  items:
  1976                    type: "string"
  1977                  example:
  1978                    - "sha256:675532206fbf3030b8458f88d6e26d4eb1577688a25efec97154c94e8b6b4887"
  1979                    - "sha256:e216a057b1cb1efc11f8a268f37ef62083e70b1b38323ba252e25ac88904a7e8"
  1980  
  1981    ObjectVersion:
  1982      description: |
  1983        The version number of the object such as node, service, etc. This is needed to avoid conflicting writes.
  1984        The client must send the version number along with the modified specification when updating these objects.
  1985        This approach ensures safe concurrency and determinism in that the change on the object
  1986        may not be applied if the version number has changed from the last read. In other words,
  1987        if two update requests specify the same base version, only one of the requests can succeed.
  1988        As a result, two separate update requests that happen at the same time will not
  1989        unintentionally overwrite each other.
  1990      type: "object"
  1991      properties:
  1992        Index:
  1993          type: "integer"
  1994          format: "uint64"
  1995          example: 373531
  1996  
  1997    NodeSpec:
  1998      type: "object"
  1999      properties:
  2000        Name:
  2001          description: "Name for the node."
  2002          type: "string"
  2003          example: "my-node"
  2004        Labels:
  2005          description: "User-defined key/value metadata."
  2006          type: "object"
  2007          additionalProperties:
  2008            type: "string"
  2009        Role:
  2010          description: "Role of the node."
  2011          type: "string"
  2012          enum:
  2013            - "worker"
  2014            - "manager"
  2015          example: "manager"
  2016        Availability:
  2017          description: "Availability of the node."
  2018          type: "string"
  2019          enum:
  2020            - "active"
  2021            - "pause"
  2022            - "drain"
  2023          example: "active"
  2024      example:
  2025        Availability: "active"
  2026        Name: "node-name"
  2027        Role: "manager"
  2028        Labels:
  2029          foo: "bar"
  2030  
  2031    Node:
  2032      type: "object"
  2033      properties:
  2034        ID:
  2035          type: "string"
  2036          example: "24ifsmvkjbyhk"
  2037        Version:
  2038          $ref: "#/definitions/ObjectVersion"
  2039        CreatedAt:
  2040          description: |
  2041            Date and time at which the node was added to the swarm in
  2042            [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  2043          type: "string"
  2044          format: "dateTime"
  2045          example: "2016-08-18T10:44:24.496525531Z"
  2046        UpdatedAt:
  2047          description: |
  2048            Date and time at which the node was last updated in
  2049            [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  2050          type: "string"
  2051          format: "dateTime"
  2052          example: "2017-08-09T07:09:37.632105588Z"
  2053        Spec:
  2054          $ref: "#/definitions/NodeSpec"
  2055        Description:
  2056          $ref: "#/definitions/NodeDescription"
  2057        Status:
  2058          $ref: "#/definitions/NodeStatus"
  2059        ManagerStatus:
  2060          $ref: "#/definitions/ManagerStatus"
  2061  
  2062    NodeDescription:
  2063      description: |
  2064        NodeDescription encapsulates the properties of the Node as reported by the
  2065        agent.
  2066      type: "object"
  2067      properties:
  2068        Hostname:
  2069          type: "string"
  2070          example: "bf3067039e47"
  2071        Platform:
  2072          $ref: "#/definitions/Platform"
  2073        Resources:
  2074          $ref: "#/definitions/ResourceObject"
  2075        Engine:
  2076          $ref: "#/definitions/EngineDescription"
  2077        TLSInfo:
  2078          $ref: "#/definitions/TLSInfo"
  2079  
  2080    Platform:
  2081      description: |
  2082        Platform represents the platform (Arch/OS).
  2083      type: "object"
  2084      properties:
  2085        Architecture:
  2086          description: |
  2087            Architecture represents the hardware architecture (for example,
  2088            `x86_64`).
  2089          type: "string"
  2090          example: "x86_64"
  2091        OS:
  2092          description: |
  2093            OS represents the Operating System (for example, `linux` or `windows`).
  2094          type: "string"
  2095          example: "linux"
  2096  
  2097    EngineDescription:
  2098      description: "EngineDescription provides information about an engine."
  2099      type: "object"
  2100      properties:
  2101        EngineVersion:
  2102          type: "string"
  2103          example: "17.06.0"
  2104        Labels:
  2105          type: "object"
  2106          additionalProperties:
  2107            type: "string"
  2108          example:
  2109            foo: "bar"
  2110        Plugins:
  2111          type: "array"
  2112          items:
  2113            type: "object"
  2114            properties:
  2115              Type:
  2116                type: "string"
  2117              Name:
  2118                type: "string"
  2119          example:
  2120            - Type: "Log"
  2121              Name: "awslogs"
  2122            - Type: "Log"
  2123              Name: "fluentd"
  2124            - Type: "Log"
  2125              Name: "gcplogs"
  2126            - Type: "Log"
  2127              Name: "gelf"
  2128            - Type: "Log"
  2129              Name: "journald"
  2130            - Type: "Log"
  2131              Name: "json-file"
  2132            - Type: "Log"
  2133              Name: "logentries"
  2134            - Type: "Log"
  2135              Name: "splunk"
  2136            - Type: "Log"
  2137              Name: "syslog"
  2138            - Type: "Network"
  2139              Name: "bridge"
  2140            - Type: "Network"
  2141              Name: "host"
  2142            - Type: "Network"
  2143              Name: "ipvlan"
  2144            - Type: "Network"
  2145              Name: "macvlan"
  2146            - Type: "Network"
  2147              Name: "null"
  2148            - Type: "Network"
  2149              Name: "overlay"
  2150            - Type: "Volume"
  2151              Name: "local"
  2152            - Type: "Volume"
  2153              Name: "localhost:5000/vieux/sshfs:latest"
  2154            - Type: "Volume"
  2155              Name: "vieux/sshfs:latest"
  2156  
  2157    TLSInfo:
  2158      description: "Information about the issuer of leaf TLS certificates and the trusted root CA certificate"
  2159      type: "object"
  2160      properties:
  2161        TrustRoot:
  2162          description: "The root CA certificate(s) that are used to validate leaf TLS certificates"
  2163          type: "string"
  2164        CertIssuerSubject:
  2165          description: "The base64-url-safe-encoded raw subject bytes of the issuer"
  2166          type: "string"
  2167        CertIssuerPublicKey:
  2168          description: "The base64-url-safe-encoded raw public key bytes of the issuer"
  2169          type: "string"
  2170      example:
  2171        TrustRoot: |
  2172          -----BEGIN CERTIFICATE-----
  2173          MIIBajCCARCgAwIBAgIUbYqrLSOSQHoxD8CwG6Bi2PJi9c8wCgYIKoZIzj0EAwIw
  2174          EzERMA8GA1UEAxMIc3dhcm0tY2EwHhcNMTcwNDI0MjE0MzAwWhcNMzcwNDE5MjE0
  2175          MzAwWjATMREwDwYDVQQDEwhzd2FybS1jYTBZMBMGByqGSM49AgEGCCqGSM49AwEH
  2176          A0IABJk/VyMPYdaqDXJb/VXh5n/1Yuv7iNrxV3Qb3l06XD46seovcDWs3IZNV1lf
  2177          3Skyr0ofcchipoiHkXBODojJydSjQjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMB
  2178          Af8EBTADAQH/MB0GA1UdDgQWBBRUXxuRcnFjDfR/RIAUQab8ZV/n4jAKBggqhkjO
  2179          PQQDAgNIADBFAiAy+JTe6Uc3KyLCMiqGl2GyWGQqQDEcO3/YG36x7om65AIhAJvz
  2180          pxv6zFeVEkAEEkqIYi0omA9+CjanB/6Bz4n1uw8H
  2181          -----END CERTIFICATE-----
  2182        CertIssuerSubject: "MBMxETAPBgNVBAMTCHN3YXJtLWNh"
  2183        CertIssuerPublicKey: "MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEmT9XIw9h1qoNclv9VeHmf/Vi6/uI2vFXdBveXTpcPjqx6i9wNazchk1XWV/dKTKvSh9xyGKmiIeRcE4OiMnJ1A=="
  2184  
  2185    NodeStatus:
  2186      description: |
  2187        NodeStatus represents the status of a node.
  2188  
  2189        It provides the current status of the node, as seen by the manager.
  2190      type: "object"
  2191      properties:
  2192        State:
  2193          $ref: "#/definitions/NodeState"
  2194        Message:
  2195          type: "string"
  2196          example: ""
  2197        Addr:
  2198          description: "IP address of the node."
  2199          type: "string"
  2200          example: "172.17.0.2"
  2201  
  2202    NodeState:
  2203      description: "NodeState represents the state of a node."
  2204      type: "string"
  2205      enum:
  2206        - "unknown"
  2207        - "down"
  2208        - "ready"
  2209        - "disconnected"
  2210      example: "ready"
  2211  
  2212    ManagerStatus:
  2213      description: |
  2214        ManagerStatus represents the status of a manager.
  2215  
  2216        It provides the current status of a node's manager component, if the node
  2217        is a manager.
  2218      x-nullable: true
  2219      type: "object"
  2220      properties:
  2221        Leader:
  2222          type: "boolean"
  2223          default: false
  2224          example: true
  2225        Reachability:
  2226          $ref: "#/definitions/Reachability"
  2227        Addr:
  2228          description: |
  2229            The IP address and port at which the manager is reachable.
  2230          type: "string"
  2231          example: "10.0.0.46:2377"
  2232  
  2233    Reachability:
  2234      description: "Reachability represents the reachability of a node."
  2235      type: "string"
  2236      enum:
  2237        - "unknown"
  2238        - "unreachable"
  2239        - "reachable"
  2240      example: "reachable"
  2241  
  2242    SwarmSpec:
  2243      description: "User modifiable swarm configuration."
  2244      type: "object"
  2245      properties:
  2246        Name:
  2247          description: "Name of the swarm."
  2248          type: "string"
  2249          example: "default"
  2250        Labels:
  2251          description: "User-defined key/value metadata."
  2252          type: "object"
  2253          additionalProperties:
  2254            type: "string"
  2255          example:
  2256            com.example.corp.type: "production"
  2257            com.example.corp.department: "engineering"
  2258        Orchestration:
  2259          description: "Orchestration configuration."
  2260          type: "object"
  2261          x-nullable: true
  2262          properties:
  2263            TaskHistoryRetentionLimit:
  2264              description: "The number of historic tasks to keep per instance or node. If negative, never remove completed or failed tasks."
  2265              type: "integer"
  2266              format: "int64"
  2267              example: 10
  2268        Raft:
  2269          description: "Raft configuration."
  2270          type: "object"
  2271          properties:
  2272            SnapshotInterval:
  2273              description: "The number of log entries between snapshots."
  2274              type: "integer"
  2275              format: "uint64"
  2276              example: 10000
  2277            KeepOldSnapshots:
  2278              description: "The number of snapshots to keep beyond the current snapshot."
  2279              type: "integer"
  2280              format: "uint64"
  2281            LogEntriesForSlowFollowers:
  2282              description: "The number of log entries to keep around to sync up slow followers after a snapshot is created."
  2283              type: "integer"
  2284              format: "uint64"
  2285              example: 500
  2286            ElectionTick:
  2287              description: |
  2288                The number of ticks that a follower will wait for a message from the leader before becoming a candidate and starting an election. `ElectionTick` must be greater than `HeartbeatTick`.
  2289  
  2290                A tick currently defaults to one second, so these translate directly to seconds currently, but this is NOT guaranteed.
  2291              type: "integer"
  2292              example: 3
  2293            HeartbeatTick:
  2294              description: |
  2295                The number of ticks between heartbeats. Every HeartbeatTick ticks, the leader will send a heartbeat to the followers.
  2296  
  2297                A tick currently defaults to one second, so these translate directly to seconds currently, but this is NOT guaranteed.
  2298              type: "integer"
  2299              example: 1
  2300        Dispatcher:
  2301          description: "Dispatcher configuration."
  2302          type: "object"
  2303          x-nullable: true
  2304          properties:
  2305            HeartbeatPeriod:
  2306              description: "The delay for an agent to send a heartbeat to the dispatcher."
  2307              type: "integer"
  2308              format: "int64"
  2309              example: 5000000000
  2310        CAConfig:
  2311          description: "CA configuration."
  2312          type: "object"
  2313          x-nullable: true
  2314          properties:
  2315            NodeCertExpiry:
  2316              description: "The duration node certificates are issued for."
  2317              type: "integer"
  2318              format: "int64"
  2319              example: 7776000000000000
  2320            ExternalCAs:
  2321              description: "Configuration for forwarding signing requests to an external certificate authority."
  2322              type: "array"
  2323              items:
  2324                type: "object"
  2325                properties:
  2326                  Protocol:
  2327                    description: "Protocol for communication with the external CA (currently only `cfssl` is supported)."
  2328                    type: "string"
  2329                    enum:
  2330                      - "cfssl"
  2331                    default: "cfssl"
  2332                  URL:
  2333                    description: "URL where certificate signing requests should be sent."
  2334                    type: "string"
  2335                  Options:
  2336                    description: "An object with key/value pairs that are interpreted as protocol-specific options for the external CA driver."
  2337                    type: "object"
  2338                    additionalProperties:
  2339                      type: "string"
  2340                  CACert:
  2341                    description: "The root CA certificate (in PEM format) this external CA uses to issue TLS certificates (assumed to be to the current swarm root CA certificate if not provided)."
  2342                    type: "string"
  2343            SigningCACert:
  2344              description: "The desired signing CA certificate for all swarm node TLS leaf certificates, in PEM format."
  2345              type: "string"
  2346            SigningCAKey:
  2347              description: "The desired signing CA key for all swarm node TLS leaf certificates, in PEM format."
  2348              type: "string"
  2349            ForceRotate:
  2350              description: "An integer whose purpose is to force swarm to generate a new signing CA certificate and key, if none have been specified in `SigningCACert` and `SigningCAKey`"
  2351              format: "uint64"
  2352              type: "integer"
  2353        EncryptionConfig:
  2354          description: "Parameters related to encryption-at-rest."
  2355          type: "object"
  2356          properties:
  2357            AutoLockManagers:
  2358              description: "If set, generate a key and use it to lock data stored on the managers."
  2359              type: "boolean"
  2360              example: false
  2361        TaskDefaults:
  2362          description: "Defaults for creating tasks in this cluster."
  2363          type: "object"
  2364          properties:
  2365            LogDriver:
  2366              description: |
  2367                The log driver to use for tasks created in the orchestrator if
  2368                unspecified by a service.
  2369  
  2370                Updating this value only affects new tasks. Existing tasks continue
  2371                to use their previously configured log driver until recreated.
  2372              type: "object"
  2373              properties:
  2374                Name:
  2375                  description: |
  2376                    The log driver to use as a default for new tasks.
  2377                  type: "string"
  2378                  example: "json-file"
  2379                Options:
  2380                  description: |
  2381                    Driver-specific options for the selectd log driver, specified
  2382                    as key/value pairs.
  2383                  type: "object"
  2384                  additionalProperties:
  2385                    type: "string"
  2386                  example:
  2387                    "max-file": "10"
  2388                    "max-size": "100m"
  2389  
  2390    # The Swarm information for `GET /info`. It is the same as `GET /swarm`, but
  2391    # without `JoinTokens`.
  2392    ClusterInfo:
  2393      description: |
  2394        ClusterInfo represents information about the swarm as is returned by the
  2395        "/info" endpoint. Join-tokens are not included.
  2396      x-nullable: true
  2397      type: "object"
  2398      properties:
  2399        ID:
  2400          description: "The ID of the swarm."
  2401          type: "string"
  2402          example: "abajmipo7b4xz5ip2nrla6b11"
  2403        Version:
  2404          $ref: "#/definitions/ObjectVersion"
  2405        CreatedAt:
  2406          description: |
  2407            Date and time at which the swarm was initialised in
  2408            [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  2409          type: "string"
  2410          format: "dateTime"
  2411          example: "2016-08-18T10:44:24.496525531Z"
  2412        UpdatedAt:
  2413          description: |
  2414            Date and time at which the swarm was last updated in
  2415            [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  2416          type: "string"
  2417          format: "dateTime"
  2418          example: "2017-08-09T07:09:37.632105588Z"
  2419        Spec:
  2420          $ref: "#/definitions/SwarmSpec"
  2421        TLSInfo:
  2422          $ref: "#/definitions/TLSInfo"
  2423        RootRotationInProgress:
  2424          description: "Whether there is currently a root CA rotation in progress for the swarm"
  2425          type: "boolean"
  2426          example: false
  2427  
  2428    JoinTokens:
  2429      description: |
  2430        JoinTokens contains the tokens workers and managers need to join the swarm.
  2431      type: "object"
  2432      properties:
  2433        Worker:
  2434          description: |
  2435            The token workers can use to join the swarm.
  2436          type: "string"
  2437          example: "SWMTKN-1-3pu6hszjas19xyp7ghgosyx9k8atbfcr8p2is99znpy26u2lkl-1awxwuwd3z9j1z3puu7rcgdbx"
  2438        Manager:
  2439          description: |
  2440            The token managers can use to join the swarm.
  2441          type: "string"
  2442          example: "SWMTKN-1-3pu6hszjas19xyp7ghgosyx9k8atbfcr8p2is99znpy26u2lkl-7p73s1dx5in4tatdymyhg9hu2"
  2443  
  2444    Swarm:
  2445      type: "object"
  2446      allOf:
  2447        - $ref: "#/definitions/ClusterInfo"
  2448        - type: "object"
  2449          properties:
  2450            JoinTokens:
  2451              $ref: "#/definitions/JoinTokens"
  2452  
  2453    TaskSpec:
  2454      description: "User modifiable task configuration."
  2455      type: "object"
  2456      properties:
  2457        PluginSpec:
  2458          type: "object"
  2459          description: "Invalid when specified with `ContainerSpec`. *(Experimental release only.)*"
  2460          properties:
  2461            Name:
  2462              description: "The name or 'alias' to use for the plugin."
  2463              type: "string"
  2464            Remote:
  2465              description: "The plugin image reference to use."
  2466              type: "string"
  2467            Disabled:
  2468              description: "Disable the plugin once scheduled."
  2469              type: "boolean"
  2470            PluginPrivilege:
  2471              type: "array"
  2472              items:
  2473                description: "Describes a permission accepted by the user upon installing the plugin."
  2474                type: "object"
  2475                properties:
  2476                  Name:
  2477                    type: "string"
  2478                  Description:
  2479                    type: "string"
  2480                  Value:
  2481                    type: "array"
  2482                    items:
  2483                      type: "string"
  2484        ContainerSpec:
  2485          type: "object"
  2486          description: "Invalid when specified with `PluginSpec`."
  2487          properties:
  2488            Image:
  2489              description: "The image name to use for the container"
  2490              type: "string"
  2491            Labels:
  2492              description: "User-defined key/value data."
  2493              type: "object"
  2494              additionalProperties:
  2495                type: "string"
  2496            Command:
  2497              description: "The command to be run in the image."
  2498              type: "array"
  2499              items:
  2500                type: "string"
  2501            Args:
  2502              description: "Arguments to the command."
  2503              type: "array"
  2504              items:
  2505                type: "string"
  2506            Hostname:
  2507              description: "The hostname to use for the container, as a valid RFC 1123 hostname."
  2508              type: "string"
  2509            Env:
  2510              description: "A list of environment variables in the form `VAR=value`."
  2511              type: "array"
  2512              items:
  2513                type: "string"
  2514            Dir:
  2515              description: "The working directory for commands to run in."
  2516              type: "string"
  2517            User:
  2518              description: "The user inside the container."
  2519              type: "string"
  2520            Groups:
  2521              type: "array"
  2522              description: "A list of additional groups that the container process will run as."
  2523              items:
  2524                type: "string"
  2525            Privileges:
  2526              type: "object"
  2527              description: "Security options for the container"
  2528              properties:
  2529                CredentialSpec:
  2530                  type: "object"
  2531                  description: "CredentialSpec for managed service account (Windows only)"
  2532                  properties:
  2533                    File:
  2534                      type: "string"
  2535                      description: |
  2536                        Load credential spec from this file. The file is read by the daemon, and must be present in the
  2537                        `CredentialSpecs` subdirectory in the docker data directory, which defaults to
  2538                        `C:\ProgramData\Docker\` on Windows.
  2539  
  2540                        For example, specifying `spec.json` loads `C:\ProgramData\Docker\CredentialSpecs\spec.json`.
  2541  
  2542                        <p><br /></p>
  2543  
  2544                        > **Note**: `CredentialSpec.File` and `CredentialSpec.Registry` are mutually exclusive.
  2545                    Registry:
  2546                      type: "string"
  2547                      description: |
  2548                        Load credential spec from this value in the Windows registry. The specified registry value must be
  2549                        located in:
  2550  
  2551                        `HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Virtualization\Containers\CredentialSpecs`
  2552  
  2553                        <p><br /></p>
  2554  
  2555  
  2556                        > **Note**: `CredentialSpec.File` and `CredentialSpec.Registry` are mutually exclusive.
  2557                SELinuxContext:
  2558                  type: "object"
  2559                  description: "SELinux labels of the container"
  2560                  properties:
  2561                    Disable:
  2562                      type: "boolean"
  2563                      description: "Disable SELinux"
  2564                    User:
  2565                      type: "string"
  2566                      description: "SELinux user label"
  2567                    Role:
  2568                      type: "string"
  2569                      description: "SELinux role label"
  2570                    Type:
  2571                      type: "string"
  2572                      description: "SELinux type label"
  2573                    Level:
  2574                      type: "string"
  2575                      description: "SELinux level label"
  2576            TTY:
  2577              description: "Whether a pseudo-TTY should be allocated."
  2578              type: "boolean"
  2579            OpenStdin:
  2580              description: "Open `stdin`"
  2581              type: "boolean"
  2582            ReadOnly:
  2583              description: "Mount the container's root filesystem as read only."
  2584              type: "boolean"
  2585            Mounts:
  2586              description: "Specification for mounts to be added to containers created as part of the service."
  2587              type: "array"
  2588              items:
  2589                $ref: "#/definitions/Mount"
  2590            StopSignal:
  2591              description: "Signal to stop the container."
  2592              type: "string"
  2593            StopGracePeriod:
  2594              description: "Amount of time to wait for the container to terminate before forcefully killing it."
  2595              type: "integer"
  2596              format: "int64"
  2597            HealthCheck:
  2598              $ref: "#/definitions/HealthConfig"
  2599            Hosts:
  2600              type: "array"
  2601              description: |
  2602                A list of hostname/IP mappings to add to the container's `hosts`
  2603                file. The format of extra hosts is specified in the
  2604                [hosts(5)](http://man7.org/linux/man-pages/man5/hosts.5.html)
  2605                man page:
  2606  
  2607                    IP_address canonical_hostname [aliases...]
  2608              items:
  2609                type: "string"
  2610            DNSConfig:
  2611              description: "Specification for DNS related configurations in resolver configuration file (`resolv.conf`)."
  2612              type: "object"
  2613              properties:
  2614                Nameservers:
  2615                  description: "The IP addresses of the name servers."
  2616                  type: "array"
  2617                  items:
  2618                    type: "string"
  2619                Search:
  2620                  description: "A search list for host-name lookup."
  2621                  type: "array"
  2622                  items:
  2623                    type: "string"
  2624                Options:
  2625                  description: "A list of internal resolver variables to be modified (e.g., `debug`, `ndots:3`, etc.)."
  2626                  type: "array"
  2627                  items:
  2628                    type: "string"
  2629            Secrets:
  2630              description: "Secrets contains references to zero or more secrets that will be exposed to the service."
  2631              type: "array"
  2632              items:
  2633                type: "object"
  2634                properties:
  2635                  File:
  2636                    description: "File represents a specific target that is backed by a file."
  2637                    type: "object"
  2638                    properties:
  2639                      Name:
  2640                        description: "Name represents the final filename in the filesystem."
  2641                        type: "string"
  2642                      UID:
  2643                        description: "UID represents the file UID."
  2644                        type: "string"
  2645                      GID:
  2646                        description: "GID represents the file GID."
  2647                        type: "string"
  2648                      Mode:
  2649                        description: "Mode represents the FileMode of the file."
  2650                        type: "integer"
  2651                        format: "uint32"
  2652                  SecretID:
  2653                    description: "SecretID represents the ID of the specific secret that we're referencing."
  2654                    type: "string"
  2655                  SecretName:
  2656                    description: |
  2657                      SecretName is the name of the secret that this references, but this is just provided for
  2658                      lookup/display purposes. The secret in the reference will be identified by its ID.
  2659                    type: "string"
  2660            Configs:
  2661              description: "Configs contains references to zero or more configs that will be exposed to the service."
  2662              type: "array"
  2663              items:
  2664                type: "object"
  2665                properties:
  2666                  File:
  2667                    description: "File represents a specific target that is backed by a file."
  2668                    type: "object"
  2669                    properties:
  2670                      Name:
  2671                        description: "Name represents the final filename in the filesystem."
  2672                        type: "string"
  2673                      UID:
  2674                        description: "UID represents the file UID."
  2675                        type: "string"
  2676                      GID:
  2677                        description: "GID represents the file GID."
  2678                        type: "string"
  2679                      Mode:
  2680                        description: "Mode represents the FileMode of the file."
  2681                        type: "integer"
  2682                        format: "uint32"
  2683                  ConfigID:
  2684                    description: "ConfigID represents the ID of the specific config that we're referencing."
  2685                    type: "string"
  2686                  ConfigName:
  2687                    description: |
  2688                      ConfigName is the name of the config that this references, but this is just provided for
  2689                      lookup/display purposes. The config in the reference will be identified by its ID.
  2690                    type: "string"
  2691  
  2692        Resources:
  2693          description: "Resource requirements which apply to each individual container created as part of the service."
  2694          type: "object"
  2695          properties:
  2696            Limits:
  2697              description: "Define resources limits."
  2698              $ref: "#/definitions/ResourceObject"
  2699            Reservation:
  2700              description: "Define resources reservation."
  2701              $ref: "#/definitions/ResourceObject"
  2702        RestartPolicy:
  2703          description: "Specification for the restart policy which applies to containers created as part of this service."
  2704          type: "object"
  2705          properties:
  2706            Condition:
  2707              description: "Condition for restart."
  2708              type: "string"
  2709              enum:
  2710                - "none"
  2711                - "on-failure"
  2712                - "any"
  2713            Delay:
  2714              description: "Delay between restart attempts."
  2715              type: "integer"
  2716              format: "int64"
  2717            MaxAttempts:
  2718              description: "Maximum attempts to restart a given container before giving up (default value is 0, which is ignored)."
  2719              type: "integer"
  2720              format: "int64"
  2721              default: 0
  2722            Window:
  2723              description: "Windows is the time window used to evaluate the restart policy (default value is 0, which is unbounded)."
  2724              type: "integer"
  2725              format: "int64"
  2726              default: 0
  2727        Placement:
  2728          type: "object"
  2729          properties:
  2730            Constraints:
  2731              description: "An array of constraints."
  2732              type: "array"
  2733              items:
  2734                type: "string"
  2735              example:
  2736                - "node.hostname!=node3.corp.example.com"
  2737                - "node.role!=manager"
  2738                - "node.labels.type==production"
  2739            Preferences:
  2740              description: "Preferences provide a way to make the scheduler aware of factors such as topology. They are provided in order from highest to lowest precedence."
  2741              type: "array"
  2742              items:
  2743                type: "object"
  2744                properties:
  2745                  Spread:
  2746                    type: "object"
  2747                    properties:
  2748                      SpreadDescriptor:
  2749                        description: "label descriptor, such as engine.labels.az"
  2750                        type: "string"
  2751              example:
  2752                - Spread:
  2753                    SpreadDescriptor: "node.labels.datacenter"
  2754                - Spread:
  2755                    SpreadDescriptor: "node.labels.rack"
  2756            Platforms:
  2757              description: |
  2758                Platforms stores all the platforms that the service's image can
  2759                run on. This field is used in the platform filter for scheduling.
  2760                If empty, then the platform filter is off, meaning there are no
  2761                scheduling restrictions.
  2762              type: "array"
  2763              items:
  2764                $ref: "#/definitions/Platform"
  2765        ForceUpdate:
  2766          description: "A counter that triggers an update even if no relevant parameters have been changed."
  2767          type: "integer"
  2768        Runtime:
  2769          description: "Runtime is the type of runtime specified for the task executor."
  2770          type: "string"
  2771        Networks:
  2772          type: "array"
  2773          items:
  2774            type: "object"
  2775            properties:
  2776              Target:
  2777                type: "string"
  2778              Aliases:
  2779                type: "array"
  2780                items:
  2781                  type: "string"
  2782        LogDriver:
  2783          description: "Specifies the log driver to use for tasks created from this spec. If not present, the default one for the swarm will be used, finally falling back to the engine default if not specified."
  2784          type: "object"
  2785          properties:
  2786            Name:
  2787              type: "string"
  2788            Options:
  2789              type: "object"
  2790              additionalProperties:
  2791                type: "string"
  2792  
  2793    TaskState:
  2794      type: "string"
  2795      enum:
  2796        - "new"
  2797        - "allocated"
  2798        - "pending"
  2799        - "assigned"
  2800        - "accepted"
  2801        - "preparing"
  2802        - "ready"
  2803        - "starting"
  2804        - "running"
  2805        - "complete"
  2806        - "shutdown"
  2807        - "failed"
  2808        - "rejected"
  2809  
  2810    Task:
  2811      type: "object"
  2812      properties:
  2813        ID:
  2814          description: "The ID of the task."
  2815          type: "string"
  2816        Version:
  2817          $ref: "#/definitions/ObjectVersion"
  2818        CreatedAt:
  2819          type: "string"
  2820          format: "dateTime"
  2821        UpdatedAt:
  2822          type: "string"
  2823          format: "dateTime"
  2824        Name:
  2825          description: "Name of the task."
  2826          type: "string"
  2827        Labels:
  2828          description: "User-defined key/value metadata."
  2829          type: "object"
  2830          additionalProperties:
  2831            type: "string"
  2832        Spec:
  2833          $ref: "#/definitions/TaskSpec"
  2834        ServiceID:
  2835          description: "The ID of the service this task is part of."
  2836          type: "string"
  2837        Slot:
  2838          type: "integer"
  2839        NodeID:
  2840          description: "The ID of the node that this task is on."
  2841          type: "string"
  2842        AssignedGenericResources:
  2843          $ref: "#/definitions/GenericResources"
  2844        Status:
  2845          type: "object"
  2846          properties:
  2847            Timestamp:
  2848              type: "string"
  2849              format: "dateTime"
  2850            State:
  2851              $ref: "#/definitions/TaskState"
  2852            Message:
  2853              type: "string"
  2854            Err:
  2855              type: "string"
  2856            ContainerStatus:
  2857              type: "object"
  2858              properties:
  2859                ContainerID:
  2860                  type: "string"
  2861                PID:
  2862                  type: "integer"
  2863                ExitCode:
  2864                  type: "integer"
  2865        DesiredState:
  2866          $ref: "#/definitions/TaskState"
  2867      example:
  2868        ID: "0kzzo1i0y4jz6027t0k7aezc7"
  2869        Version:
  2870          Index: 71
  2871        CreatedAt: "2016-06-07T21:07:31.171892745Z"
  2872        UpdatedAt: "2016-06-07T21:07:31.376370513Z"
  2873        Spec:
  2874          ContainerSpec:
  2875            Image: "redis"
  2876          Resources:
  2877            Limits: {}
  2878            Reservations: {}
  2879          RestartPolicy:
  2880            Condition: "any"
  2881            MaxAttempts: 0
  2882          Placement: {}
  2883        ServiceID: "9mnpnzenvg8p8tdbtq4wvbkcz"
  2884        Slot: 1
  2885        NodeID: "60gvrl6tm78dmak4yl7srz94v"
  2886        Status:
  2887          Timestamp: "2016-06-07T21:07:31.290032978Z"
  2888          State: "running"
  2889          Message: "started"
  2890          ContainerStatus:
  2891            ContainerID: "e5d62702a1b48d01c3e02ca1e0212a250801fa8d67caca0b6f35919ebc12f035"
  2892            PID: 677
  2893        DesiredState: "running"
  2894        NetworksAttachments:
  2895          - Network:
  2896              ID: "4qvuz4ko70xaltuqbt8956gd1"
  2897              Version:
  2898                Index: 18
  2899              CreatedAt: "2016-06-07T20:31:11.912919752Z"
  2900              UpdatedAt: "2016-06-07T21:07:29.955277358Z"
  2901              Spec:
  2902                Name: "ingress"
  2903                Labels:
  2904                  com.docker.swarm.internal: "true"
  2905                DriverConfiguration: {}
  2906                IPAMOptions:
  2907                  Driver: {}
  2908                  Configs:
  2909                    - Subnet: "10.255.0.0/16"
  2910                      Gateway: "10.255.0.1"
  2911              DriverState:
  2912                Name: "overlay"
  2913                Options:
  2914                  com.docker.network.driver.overlay.vxlanid_list: "256"
  2915              IPAMOptions:
  2916                Driver:
  2917                  Name: "default"
  2918                Configs:
  2919                  - Subnet: "10.255.0.0/16"
  2920                    Gateway: "10.255.0.1"
  2921            Addresses:
  2922              - "10.255.0.10/16"
  2923        AssignedGenericResources:
  2924          - DiscreteResourceSpec:
  2925              Kind: "SSD"
  2926              Value: 3
  2927          - NamedResourceSpec:
  2928              Kind: "GPU"
  2929              Value: "UUID1"
  2930          - NamedResourceSpec:
  2931              Kind: "GPU"
  2932              Value: "UUID2"
  2933  
  2934    ServiceSpec:
  2935      description: "User modifiable configuration for a service."
  2936      properties:
  2937        Name:
  2938          description: "Name of the service."
  2939          type: "string"
  2940        Labels:
  2941          description: "User-defined key/value metadata."
  2942          type: "object"
  2943          additionalProperties:
  2944            type: "string"
  2945        TaskTemplate:
  2946          $ref: "#/definitions/TaskSpec"
  2947        Mode:
  2948          description: "Scheduling mode for the service."
  2949          type: "object"
  2950          properties:
  2951            Replicated:
  2952              type: "object"
  2953              properties:
  2954                Replicas:
  2955                  type: "integer"
  2956                  format: "int64"
  2957            Global:
  2958              type: "object"
  2959        UpdateConfig:
  2960          description: "Specification for the update strategy of the service."
  2961          type: "object"
  2962          properties:
  2963            Parallelism:
  2964              description: "Maximum number of tasks to be updated in one iteration (0 means unlimited parallelism)."
  2965              type: "integer"
  2966              format: "int64"
  2967            Delay:
  2968              description: "Amount of time between updates, in nanoseconds."
  2969              type: "integer"
  2970              format: "int64"
  2971            FailureAction:
  2972              description: "Action to take if an updated task fails to run, or stops running during the update."
  2973              type: "string"
  2974              enum:
  2975                - "continue"
  2976                - "pause"
  2977                - "rollback"
  2978            Monitor:
  2979              description: "Amount of time to monitor each updated task for failures, in nanoseconds."
  2980              type: "integer"
  2981              format: "int64"
  2982            MaxFailureRatio:
  2983              description: "The fraction of tasks that may fail during an update before the failure action is invoked, specified as a floating point number between 0 and 1."
  2984              type: "number"
  2985              default: 0
  2986            Order:
  2987              description: "The order of operations when rolling out an updated task. Either the old task is shut down before the new task is started, or the new task is started before the old task is shut down."
  2988              type: "string"
  2989              enum:
  2990                - "stop-first"
  2991                - "start-first"
  2992        RollbackConfig:
  2993          description: "Specification for the rollback strategy of the service."
  2994          type: "object"
  2995          properties:
  2996            Parallelism:
  2997              description: "Maximum number of tasks to be rolled back in one iteration (0 means unlimited parallelism)."
  2998              type: "integer"
  2999              format: "int64"
  3000            Delay:
  3001              description: "Amount of time between rollback iterations, in nanoseconds."
  3002              type: "integer"
  3003              format: "int64"
  3004            FailureAction:
  3005              description: "Action to take if an rolled back task fails to run, or stops running during the rollback."
  3006              type: "string"
  3007              enum:
  3008                - "continue"
  3009                - "pause"
  3010            Monitor:
  3011              description: "Amount of time to monitor each rolled back task for failures, in nanoseconds."
  3012              type: "integer"
  3013              format: "int64"
  3014            MaxFailureRatio:
  3015              description: "The fraction of tasks that may fail during a rollback before the failure action is invoked, specified as a floating point number between 0 and 1."
  3016              type: "number"
  3017              default: 0
  3018            Order:
  3019              description: "The order of operations when rolling back a task. Either the old task is shut down before the new task is started, or the new task is started before the old task is shut down."
  3020              type: "string"
  3021              enum:
  3022                - "stop-first"
  3023                - "start-first"
  3024        Networks:
  3025          description: "Array of network names or IDs to attach the service to."
  3026          type: "array"
  3027          items:
  3028            type: "object"
  3029            properties:
  3030              Target:
  3031                type: "string"
  3032              Aliases:
  3033                type: "array"
  3034                items:
  3035                  type: "string"
  3036        EndpointSpec:
  3037          $ref: "#/definitions/EndpointSpec"
  3038  
  3039    EndpointPortConfig:
  3040      type: "object"
  3041      properties:
  3042        Name:
  3043          type: "string"
  3044        Protocol:
  3045          type: "string"
  3046          enum:
  3047            - "tcp"
  3048            - "udp"
  3049        TargetPort:
  3050          description: "The port inside the container."
  3051          type: "integer"
  3052        PublishedPort:
  3053          description: "The port on the swarm hosts."
  3054          type: "integer"
  3055        PublishMode:
  3056          description: |
  3057            The mode in which port is published.
  3058  
  3059            <p><br /></p>
  3060  
  3061            - "ingress" makes the target port accessible on on every node,
  3062              regardless of whether there is a task for the service running on
  3063              that node or not.
  3064            - "host" bypasses the routing mesh and publish the port directly on
  3065              the swarm node where that service is running.
  3066  
  3067          type: "string"
  3068          enum:
  3069            - "ingress"
  3070            - "host"
  3071          default: "ingress"
  3072          example: "ingress"
  3073  
  3074    EndpointSpec:
  3075      description: "Properties that can be configured to access and load balance a service."
  3076      type: "object"
  3077      properties:
  3078        Mode:
  3079          description: "The mode of resolution to use for internal load balancing
  3080        between tasks."
  3081          type: "string"
  3082          enum:
  3083            - "vip"
  3084            - "dnsrr"
  3085          default: "vip"
  3086        Ports:
  3087          description: "List of exposed ports that this service is accessible on from the outside. Ports can only be provided if `vip` resolution mode is used."
  3088          type: "array"
  3089          items:
  3090            $ref: "#/definitions/EndpointPortConfig"
  3091  
  3092    Service:
  3093      type: "object"
  3094      properties:
  3095        ID:
  3096          type: "string"
  3097        Version:
  3098          $ref: "#/definitions/ObjectVersion"
  3099        CreatedAt:
  3100          type: "string"
  3101          format: "dateTime"
  3102        UpdatedAt:
  3103          type: "string"
  3104          format: "dateTime"
  3105        Spec:
  3106          $ref: "#/definitions/ServiceSpec"
  3107        Endpoint:
  3108          type: "object"
  3109          properties:
  3110            Spec:
  3111              $ref: "#/definitions/EndpointSpec"
  3112            Ports:
  3113              type: "array"
  3114              items:
  3115                $ref: "#/definitions/EndpointPortConfig"
  3116            VirtualIPs:
  3117              type: "array"
  3118              items:
  3119                type: "object"
  3120                properties:
  3121                  NetworkID:
  3122                    type: "string"
  3123                  Addr:
  3124                    type: "string"
  3125        UpdateStatus:
  3126          description: "The status of a service update."
  3127          type: "object"
  3128          properties:
  3129            State:
  3130              type: "string"
  3131              enum:
  3132                - "updating"
  3133                - "paused"
  3134                - "completed"
  3135            StartedAt:
  3136              type: "string"
  3137              format: "dateTime"
  3138            CompletedAt:
  3139              type: "string"
  3140              format: "dateTime"
  3141            Message:
  3142              type: "string"
  3143      example:
  3144        ID: "9mnpnzenvg8p8tdbtq4wvbkcz"
  3145        Version:
  3146          Index: 19
  3147        CreatedAt: "2016-06-07T21:05:51.880065305Z"
  3148        UpdatedAt: "2016-06-07T21:07:29.962229872Z"
  3149        Spec:
  3150          Name: "hopeful_cori"
  3151          TaskTemplate:
  3152            ContainerSpec:
  3153              Image: "redis"
  3154            Resources:
  3155              Limits: {}
  3156              Reservations: {}
  3157            RestartPolicy:
  3158              Condition: "any"
  3159              MaxAttempts: 0
  3160            Placement: {}
  3161            ForceUpdate: 0
  3162          Mode:
  3163            Replicated:
  3164              Replicas: 1
  3165          UpdateConfig:
  3166            Parallelism: 1
  3167            Delay: 1000000000
  3168            FailureAction: "pause"
  3169            Monitor: 15000000000
  3170            MaxFailureRatio: 0.15
  3171          RollbackConfig:
  3172            Parallelism: 1
  3173            Delay: 1000000000
  3174            FailureAction: "pause"
  3175            Monitor: 15000000000
  3176            MaxFailureRatio: 0.15
  3177          EndpointSpec:
  3178            Mode: "vip"
  3179            Ports:
  3180              -
  3181                Protocol: "tcp"
  3182                TargetPort: 6379
  3183                PublishedPort: 30001
  3184        Endpoint:
  3185          Spec:
  3186            Mode: "vip"
  3187            Ports:
  3188              -
  3189                Protocol: "tcp"
  3190                TargetPort: 6379
  3191                PublishedPort: 30001
  3192          Ports:
  3193            -
  3194              Protocol: "tcp"
  3195              TargetPort: 6379
  3196              PublishedPort: 30001
  3197          VirtualIPs:
  3198            -
  3199              NetworkID: "4qvuz4ko70xaltuqbt8956gd1"
  3200              Addr: "10.255.0.2/16"
  3201            -
  3202              NetworkID: "4qvuz4ko70xaltuqbt8956gd1"
  3203              Addr: "10.255.0.3/16"
  3204  
  3205    ImageDeleteResponseItem:
  3206      type: "object"
  3207      properties:
  3208        Untagged:
  3209          description: "The image ID of an image that was untagged"
  3210          type: "string"
  3211        Deleted:
  3212          description: "The image ID of an image that was deleted"
  3213          type: "string"
  3214  
  3215    ServiceUpdateResponse:
  3216      type: "object"
  3217      properties:
  3218        Warnings:
  3219          description: "Optional warning messages"
  3220          type: "array"
  3221          items:
  3222            type: "string"
  3223      example:
  3224        Warning: "unable to pin image doesnotexist:latest to digest: image library/doesnotexist:latest not found"
  3225  
  3226    ContainerSummary:
  3227      type: "array"
  3228      items:
  3229        type: "object"
  3230        properties:
  3231          Id:
  3232            description: "The ID of this container"
  3233            type: "string"
  3234            x-go-name: "ID"
  3235          Names:
  3236            description: "The names that this container has been given"
  3237            type: "array"
  3238            items:
  3239              type: "string"
  3240          Image:
  3241            description: "The name of the image used when creating this container"
  3242            type: "string"
  3243          ImageID:
  3244            description: "The ID of the image that this container was created from"
  3245            type: "string"
  3246          Command:
  3247            description: "Command to run when starting the container"
  3248            type: "string"
  3249          Created:
  3250            description: "When the container was created"
  3251            type: "integer"
  3252            format: "int64"
  3253          Ports:
  3254            description: "The ports exposed by this container"
  3255            type: "array"
  3256            items:
  3257              $ref: "#/definitions/Port"
  3258          SizeRw:
  3259            description: "The size of files that have been created or changed by this container"
  3260            type: "integer"
  3261            format: "int64"
  3262          SizeRootFs:
  3263            description: "The total size of all the files in this container"
  3264            type: "integer"
  3265            format: "int64"
  3266          Labels:
  3267            description: "User-defined key/value metadata."
  3268            type: "object"
  3269            additionalProperties:
  3270              type: "string"
  3271          State:
  3272            description: "The state of this container (e.g. `Exited`)"
  3273            type: "string"
  3274          Status:
  3275            description: "Additional human-readable status of this container (e.g. `Exit 0`)"
  3276            type: "string"
  3277          HostConfig:
  3278            type: "object"
  3279            properties:
  3280              NetworkMode:
  3281                type: "string"
  3282          NetworkSettings:
  3283            description: "A summary of the container's network settings"
  3284            type: "object"
  3285            properties:
  3286              Networks:
  3287                type: "object"
  3288                additionalProperties:
  3289                  $ref: "#/definitions/EndpointSettings"
  3290          Mounts:
  3291            type: "array"
  3292            items:
  3293              $ref: "#/definitions/Mount"
  3294  
  3295    Driver:
  3296      description: "Driver represents a driver (network, logging, secrets)."
  3297      type: "object"
  3298      required: [Name]
  3299      properties:
  3300        Name:
  3301          description: "Name of the driver."
  3302          type: "string"
  3303          x-nullable: false
  3304          example: "some-driver"
  3305        Options:
  3306          description: "Key/value map of driver-specific options."
  3307          type: "object"
  3308          x-nullable: false
  3309          additionalProperties:
  3310            type: "string"
  3311          example:
  3312            OptionA: "value for driver-specific option A"
  3313            OptionB: "value for driver-specific option B"
  3314  
  3315    SecretSpec:
  3316      type: "object"
  3317      properties:
  3318        Name:
  3319          description: "User-defined name of the secret."
  3320          type: "string"
  3321        Labels:
  3322          description: "User-defined key/value metadata."
  3323          type: "object"
  3324          additionalProperties:
  3325            type: "string"
  3326          example:
  3327            com.example.some-label: "some-value"
  3328            com.example.some-other-label: "some-other-value"
  3329        Data:
  3330          description: |
  3331            Base64-url-safe-encoded ([RFC 4648](https://tools.ietf.org/html/rfc4648#section-3.2))
  3332            data to store as secret.
  3333  
  3334            This field is only used to _create_ a secret, and is not returned by
  3335            other endpoints.
  3336          type: "string"
  3337          example: ""
  3338        Driver:
  3339          description: "Name of the secrets driver used to fetch the secret's value from an external secret store"
  3340          $ref: "#/definitions/Driver"
  3341  
  3342    Secret:
  3343      type: "object"
  3344      properties:
  3345        ID:
  3346          type: "string"
  3347          example: "blt1owaxmitz71s9v5zh81zun"
  3348        Version:
  3349          $ref: "#/definitions/ObjectVersion"
  3350        CreatedAt:
  3351          type: "string"
  3352          format: "dateTime"
  3353          example: "2017-07-20T13:55:28.678958722Z"
  3354        UpdatedAt:
  3355          type: "string"
  3356          format: "dateTime"
  3357          example: "2017-07-20T13:55:28.678958722Z"
  3358        Spec:
  3359          $ref: "#/definitions/SecretSpec"
  3360  
  3361    ConfigSpec:
  3362      type: "object"
  3363      properties:
  3364        Name:
  3365          description: "User-defined name of the config."
  3366          type: "string"
  3367        Labels:
  3368          description: "User-defined key/value metadata."
  3369          type: "object"
  3370          additionalProperties:
  3371            type: "string"
  3372        Data:
  3373          description: |
  3374            Base64-url-safe-encoded ([RFC 4648](https://tools.ietf.org/html/rfc4648#section-3.2))
  3375            config data.
  3376          type: "string"
  3377  
  3378    Config:
  3379      type: "object"
  3380      properties:
  3381        ID:
  3382          type: "string"
  3383        Version:
  3384          $ref: "#/definitions/ObjectVersion"
  3385        CreatedAt:
  3386          type: "string"
  3387          format: "dateTime"
  3388        UpdatedAt:
  3389          type: "string"
  3390          format: "dateTime"
  3391        Spec:
  3392          $ref: "#/definitions/ConfigSpec"
  3393  
  3394    SystemInfo:
  3395      type: "object"
  3396      properties:
  3397        ID:
  3398          description: |
  3399            Unique identifier of the daemon.
  3400  
  3401            <p><br /></p>
  3402  
  3403            > **Note**: The format of the ID itself is not part of the API, and
  3404            > should not be considered stable.
  3405          type: "string"
  3406          example: "7TRN:IPZB:QYBB:VPBQ:UMPP:KARE:6ZNR:XE6T:7EWV:PKF4:ZOJD:TPYS"
  3407        Containers:
  3408          description: "Total number of containers on the host."
  3409          type: "integer"
  3410          example: 14
  3411        ContainersRunning:
  3412          description: |
  3413            Number of containers with status `"running"`.
  3414          type: "integer"
  3415          example: 3
  3416        ContainersPaused:
  3417          description: |
  3418            Number of containers with status `"paused"`.
  3419          type: "integer"
  3420          example: 1
  3421        ContainersStopped:
  3422          description: |
  3423            Number of containers with status `"stopped"`.
  3424          type: "integer"
  3425          example: 10
  3426        Images:
  3427          description: |
  3428            Total number of images on the host.
  3429  
  3430            Both _tagged_ and _untagged_ (dangling) images are counted.
  3431          type: "integer"
  3432          example: 508
  3433        Driver:
  3434          description: "Name of the storage driver in use."
  3435          type: "string"
  3436          example: "overlay2"
  3437        DriverStatus:
  3438          description: |
  3439            Information specific to the storage driver, provided as
  3440            "label" / "value" pairs.
  3441  
  3442            This information is provided by the storage driver, and formatted
  3443            in a way consistent with the output of `docker info` on the command
  3444            line.
  3445  
  3446            <p><br /></p>
  3447  
  3448            > **Note**: The information returned in this field, including the
  3449            > formatting of values and labels, should not be considered stable,
  3450            > and may change without notice.
  3451          type: "array"
  3452          items:
  3453            type: "array"
  3454            items:
  3455              type: "string"
  3456          example:
  3457            - ["Backing Filesystem", "extfs"]
  3458            - ["Supports d_type", "true"]
  3459            - ["Native Overlay Diff", "true"]
  3460        DockerRootDir:
  3461          description: |
  3462            Root directory of persistent Docker state.
  3463  
  3464            Defaults to `/var/lib/docker` on Linux, and `C:\ProgramData\docker`
  3465            on Windows.
  3466          type: "string"
  3467          example: "/var/lib/docker"
  3468        SystemStatus:
  3469          description: |
  3470            Status information about this node (standalone Swarm API).
  3471  
  3472            <p><br /></p>
  3473  
  3474            > **Note**: The information returned in this field is only propagated
  3475            > by the Swarm standalone API, and is empty (`null`) when using
  3476            > built-in swarm mode.
  3477          type: "array"
  3478          items:
  3479            type: "array"
  3480            items:
  3481              type: "string"
  3482          example:
  3483            - ["Role", "primary"]
  3484            - ["State", "Healthy"]
  3485            - ["Strategy", "spread"]
  3486            - ["Filters", "health, port, containerslots, dependency, affinity, constraint, whitelist"]
  3487            - ["Nodes", "2"]
  3488            - [" swarm-agent-00", "192.168.99.102:2376"]
  3489            - ["  └ ID", "5CT6:FBGO:RVGO:CZL4:PB2K:WCYN:2JSV:KSHH:GGFW:QOPG:6J5Q:IOZ2|192.168.99.102:2376"]
  3490            - ["  └ Status", "Healthy"]
  3491            - ["  └ Containers", "1 (1 Running, 0 Paused, 0 Stopped)"]
  3492            - ["  └ Reserved CPUs", "0 / 1"]
  3493            - ["  └ Reserved Memory", "0 B / 1.021 GiB"]
  3494            - ["  └ Labels", "kernelversion=4.4.74-boot2docker, operatingsystem=Boot2Docker 17.06.0-ce (TCL 7.2); HEAD : 0672754 - Thu Jun 29 00:06:31 UTC 2017, ostype=linux, provider=virtualbox, storagedriver=aufs"]
  3495            - ["  └ UpdatedAt", "2017-08-09T10:03:46Z"]
  3496            - ["  └ ServerVersion", "17.06.0-ce"]
  3497            - [" swarm-manager", "192.168.99.101:2376"]
  3498            - ["  └ ID", "TAMD:7LL3:SEF7:LW2W:4Q2X:WVFH:RTXX:JSYS:XY2P:JEHL:ZMJK:JGIW|192.168.99.101:2376"]
  3499            - ["  └ Status", "Healthy"]
  3500            - ["  └ Containers", "2 (2 Running, 0 Paused, 0 Stopped)"]
  3501            - ["  └ Reserved CPUs", "0 / 1"]
  3502            - ["  └ Reserved Memory", "0 B / 1.021 GiB"]
  3503            - ["  └ Labels", "kernelversion=4.4.74-boot2docker, operatingsystem=Boot2Docker 17.06.0-ce (TCL 7.2); HEAD : 0672754 - Thu Jun 29 00:06:31 UTC 2017, ostype=linux, provider=virtualbox, storagedriver=aufs"]
  3504            - ["  └ UpdatedAt", "2017-08-09T10:04:11Z"]
  3505            - ["  └ ServerVersion", "17.06.0-ce"]
  3506        Plugins:
  3507          $ref: "#/definitions/PluginsInfo"
  3508        MemoryLimit:
  3509          description: "Indicates if the host has memory limit support enabled."
  3510          type: "boolean"
  3511          example: true
  3512        SwapLimit:
  3513          description: "Indicates if the host has memory swap limit support enabled."
  3514          type: "boolean"
  3515          example: true
  3516        KernelMemory:
  3517          description: "Indicates if the host has kernel memory limit support enabled."
  3518          type: "boolean"
  3519          example: true
  3520        CpuCfsPeriod:
  3521          description: "Indicates if CPU CFS(Completely Fair Scheduler) period is supported by the host."
  3522          type: "boolean"
  3523          example: true
  3524        CpuCfsQuota:
  3525          description: "Indicates if CPU CFS(Completely Fair Scheduler) quota is supported by the host."
  3526          type: "boolean"
  3527          example: true
  3528        CPUShares:
  3529          description: "Indicates if CPU Shares limiting is supported by the host."
  3530          type: "boolean"
  3531          example: true
  3532        CPUSet:
  3533          description: |
  3534            Indicates if CPUsets (cpuset.cpus, cpuset.mems) are supported by the host.
  3535  
  3536            See [cpuset(7)](https://www.kernel.org/doc/Documentation/cgroup-v1/cpusets.txt)
  3537          type: "boolean"
  3538          example: true
  3539        OomKillDisable:
  3540          description: "Indicates if OOM killer disable is supported on the host."
  3541          type: "boolean"
  3542        IPv4Forwarding:
  3543          description: "Indicates IPv4 forwarding is enabled."
  3544          type: "boolean"
  3545          example: true
  3546        BridgeNfIptables:
  3547          description: "Indicates if `bridge-nf-call-iptables` is available on the host."
  3548          type: "boolean"
  3549          example: true
  3550        BridgeNfIp6tables:
  3551          description: "Indicates if `bridge-nf-call-ip6tables` is available on the host."
  3552          type: "boolean"
  3553          example: true
  3554        Debug:
  3555          description: "Indicates if the daemon is running in debug-mode / with debug-level logging enabled."
  3556          type: "boolean"
  3557          example: true
  3558        NFd:
  3559          description: |
  3560            The total number of file Descriptors in use by the daemon process.
  3561  
  3562            This information is only returned if debug-mode is enabled.
  3563          type: "integer"
  3564          example: 64
  3565        NGoroutines:
  3566          description: |
  3567            The  number of goroutines that currently exist.
  3568  
  3569            This information is only returned if debug-mode is enabled.
  3570          type: "integer"
  3571          example: 174
  3572        SystemTime:
  3573          description: |
  3574            Current system-time in [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt)
  3575            format with nano-seconds.
  3576          type: "string"
  3577          example: "2017-08-08T20:28:29.06202363Z"
  3578        LoggingDriver:
  3579          description: |
  3580            The logging driver to use as a default for new containers.
  3581          type: "string"
  3582        CgroupDriver:
  3583          description: |
  3584            The driver to use for managing cgroups.
  3585          type: "string"
  3586          enum: ["cgroupfs", "systemd"]
  3587          default: "cgroupfs"
  3588          example: "cgroupfs"
  3589        NEventsListener:
  3590          description: "Number of event listeners subscribed."
  3591          type: "integer"
  3592          example: 30
  3593        KernelVersion:
  3594          description: |
  3595            Kernel version of the host.
  3596  
  3597            On Linux, this information obtained from `uname`. On Windows this
  3598            information is queried from the <kbd>HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\</kbd>
  3599            registry value, for example _"10.0 14393 (14393.1198.amd64fre.rs1_release_sec.170427-1353)"_.
  3600          type: "string"
  3601          example: "4.9.38-moby"
  3602        OperatingSystem:
  3603          description: |
  3604            Name of the host's operating system, for example: "Ubuntu 16.04.2 LTS"
  3605            or "Windows Server 2016 Datacenter"
  3606          type: "string"
  3607          example: "Alpine Linux v3.5"
  3608        OSType:
  3609          description: |
  3610            Generic type of the operating system of the host, as returned by the
  3611            Go runtime (`GOOS`).
  3612  
  3613            Currently returned values are "linux" and "windows". A full list of
  3614            possible values can be found in the [Go documentation](https://golang.org/doc/install/source#environment).
  3615          type: "string"
  3616          example: "linux"
  3617        Architecture:
  3618          description: |
  3619            Hardware architecture of the host, as returned by the Go runtime
  3620            (`GOARCH`).
  3621  
  3622            A full list of possible values can be found in the [Go documentation](https://golang.org/doc/install/source#environment).
  3623          type: "string"
  3624          example: "x86_64"
  3625        NCPU:
  3626          description: |
  3627            The number of logical CPUs usable by the daemon.
  3628  
  3629            The number of available CPUs is checked by querying the operating
  3630            system when the daemon starts. Changes to operating system CPU
  3631            allocation after the daemon is started are not reflected.
  3632          type: "integer"
  3633          example: 4
  3634        MemTotal:
  3635          description: |
  3636            Total amount of physical memory available on the host, in kilobytes (kB).
  3637          type: "integer"
  3638          format: "int64"
  3639          example: 2095882240
  3640  
  3641        IndexServerAddress:
  3642          description: |
  3643            Address / URL of the index server that is used for image search,
  3644            and as a default for user authentication for Docker Hub and Docker Cloud.
  3645          default: "https://index.docker.io/v1/"
  3646          type: "string"
  3647          example: "https://index.docker.io/v1/"
  3648        RegistryConfig:
  3649          $ref: "#/definitions/RegistryServiceConfig"
  3650        GenericResources:
  3651          $ref: "#/definitions/GenericResources"
  3652        HttpProxy:
  3653          description: |
  3654            HTTP-proxy configured for the daemon. This value is obtained from the
  3655            [`HTTP_PROXY`](https://www.gnu.org/software/wget/manual/html_node/Proxies.html) environment variable.
  3656  
  3657            Containers do not automatically inherit this configuration.
  3658          type: "string"
  3659          example: "http://user:pass@proxy.corp.example.com:8080"
  3660        HttpsProxy:
  3661          description: |
  3662            HTTPS-proxy configured for the daemon. This value is obtained from the
  3663            [`HTTPS_PROXY`](https://www.gnu.org/software/wget/manual/html_node/Proxies.html) environment variable.
  3664  
  3665            Containers do not automatically inherit this configuration.
  3666          type: "string"
  3667          example: "https://user:pass@proxy.corp.example.com:4443"
  3668        NoProxy:
  3669          description: |
  3670            Comma-separated list of domain extensions for which no proxy should be
  3671            used. This value is obtained from the [`NO_PROXY`](https://www.gnu.org/software/wget/manual/html_node/Proxies.html)
  3672            environment variable.
  3673  
  3674            Containers do not automatically inherit this configuration.
  3675          type: "string"
  3676          example: "*.local, 169.254/16"
  3677        Name:
  3678          description: "Hostname of the host."
  3679          type: "string"
  3680          example: "node5.corp.example.com"
  3681        Labels:
  3682          description: |
  3683            User-defined labels (key/value metadata) as set on the daemon.
  3684  
  3685            <p><br /></p>
  3686  
  3687            > **Note**: When part of a Swarm, nodes can both have _daemon_ labels,
  3688            > set through the daemon configuration, and _node_ labels, set from a
  3689            > manager node in the Swarm. Node labels are not included in this
  3690            > field. Node labels can be retrieved using the `/nodes/(id)` endpoint
  3691            > on a manager node in the Swarm.
  3692          type: "array"
  3693          items:
  3694            type: "string"
  3695          example: ["storage=ssd", "production"]
  3696        ExperimentalBuild:
  3697          description: |
  3698            Indicates if experimental features are enabled on the daemon.
  3699          type: "boolean"
  3700          example: true
  3701        ServerVersion:
  3702          description: |
  3703            Version string of the daemon.
  3704  
  3705            > **Note**: the [standalone Swarm API](https://docs.docker.com/swarm/swarm-api/)
  3706            > returns the Swarm version instead of the daemon  version, for example
  3707            > `swarm/1.2.8`.
  3708          type: "string"
  3709          example: "17.06.0-ce"
  3710        ClusterStore:
  3711          description: |
  3712            URL of the distributed storage backend.
  3713  
  3714  
  3715            The storage backend is used for multihost networking (to store
  3716            network and endpoint information) and by the node discovery mechanism.
  3717  
  3718            <p><br /></p>
  3719  
  3720            > **Note**: This field is only propagated when using standalone Swarm
  3721            > mode, and overlay networking using an external k/v store. Overlay
  3722            > networks with Swarm mode enabled use the built-in raft store, and
  3723            > this field will be empty.
  3724          type: "string"
  3725          example: "consul://consul.corp.example.com:8600/some/path"
  3726        ClusterAdvertise:
  3727          description: |
  3728            The network endpoint that the Engine advertises for the purpose of
  3729            node discovery. ClusterAdvertise is a `host:port` combination on which
  3730            the daemon is reachable by other hosts.
  3731  
  3732            <p><br /></p>
  3733  
  3734            > **Note**: This field is only propagated when using standalone Swarm
  3735            > mode, and overlay networking using an external k/v store. Overlay
  3736            > networks with Swarm mode enabled use the built-in raft store, and
  3737            > this field will be empty.
  3738          type: "string"
  3739          example: "node5.corp.example.com:8000"
  3740        Runtimes:
  3741          description: |
  3742            List of [OCI compliant](https://github.com/opencontainers/runtime-spec)
  3743            runtimes configured on the daemon. Keys hold the "name" used to
  3744            reference the runtime.
  3745  
  3746            The Docker daemon relies on an OCI compliant runtime (invoked via the
  3747            `containerd` daemon) as its interface to the Linux kernel namespaces,
  3748            cgroups, and SELinux.
  3749  
  3750            The default runtime is `runc`, and automatically configured. Additional
  3751            runtimes can be configured by the user and will be listed here.
  3752          type: "object"
  3753          additionalProperties:
  3754            $ref: "#/definitions/Runtime"
  3755          default:
  3756            runc:
  3757              path: "docker-runc"
  3758          example:
  3759            runc:
  3760              path: "docker-runc"
  3761            runc-master:
  3762              path: "/go/bin/runc"
  3763            custom:
  3764              path: "/usr/local/bin/my-oci-runtime"
  3765              runtimeArgs: ["--debug", "--systemd-cgroup=false"]
  3766        DefaultRuntime:
  3767          description: |
  3768            Name of the default OCI runtime that is used when starting containers.
  3769  
  3770            The default can be overridden per-container at create time.
  3771          type: "string"
  3772          default: "runc"
  3773          example: "runc"
  3774        Swarm:
  3775          $ref: "#/definitions/SwarmInfo"
  3776        LiveRestoreEnabled:
  3777          description: |
  3778            Indicates if live restore is enabled.
  3779  
  3780            If enabled, containers are kept running when the daemon is shutdown
  3781            or upon daemon start if running containers are detected.
  3782          type: "boolean"
  3783          default: false
  3784          example: false
  3785        Isolation:
  3786          description: |
  3787            Represents the isolation technology to use as a default for containers.
  3788            The supported values are platform-specific.
  3789  
  3790            If no isolation value is specified on daemon start, on Windows client,
  3791            the default is `hyperv`, and on Windows server, the default is `process`.
  3792  
  3793            This option is currently not used on other platforms.
  3794          default: "default"
  3795          type: "string"
  3796          enum:
  3797            - "default"
  3798            - "hyperv"
  3799            - "process"
  3800        InitBinary:
  3801          description: |
  3802            Name and, optional, path of the the `docker-init` binary.
  3803  
  3804            If the path is omitted, the daemon searches the host's `$PATH` for the
  3805            binary and uses the first result.
  3806          type: "string"
  3807          example: "docker-init"
  3808        ContainerdCommit:
  3809          $ref: "#/definitions/Commit"
  3810        RuncCommit:
  3811          $ref: "#/definitions/Commit"
  3812        InitCommit:
  3813          $ref: "#/definitions/Commit"
  3814        SecurityOptions:
  3815          description: |
  3816            List of security features that are enabled on the daemon, such as
  3817            apparmor, seccomp, SELinux, and user-namespaces (userns).
  3818  
  3819            Additional configuration options for each security feature may
  3820            be present, and are included as a comma-separated list of key/value
  3821            pairs.
  3822          type: "array"
  3823          items:
  3824            type: "string"
  3825          example:
  3826            - "name=apparmor"
  3827            - "name=seccomp,profile=default"
  3828            - "name=selinux"
  3829            - "name=userns"
  3830  
  3831  
  3832    # PluginsInfo is a temp struct holding Plugins name
  3833    # registered with docker daemon. It is used by Info struct
  3834    PluginsInfo:
  3835      description: |
  3836        Available plugins per type.
  3837  
  3838        <p><br /></p>
  3839  
  3840        > **Note**: Only unmanaged (V1) plugins are included in this list.
  3841        > V1 plugins are "lazily" loaded, and are not returned in this list
  3842        > if there is no resource using the plugin.
  3843      type: "object"
  3844      properties:
  3845        Volume:
  3846          description: "Names of available volume-drivers, and network-driver plugins."
  3847          type: "array"
  3848          items:
  3849            type: "string"
  3850          example: ["local"]
  3851        Network:
  3852          description: "Names of available network-drivers, and network-driver plugins."
  3853          type: "array"
  3854          items:
  3855            type: "string"
  3856          example: ["bridge", "host", "ipvlan", "macvlan", "null", "overlay"]
  3857        Authorization:
  3858          description: "Names of available authorization plugins."
  3859          type: "array"
  3860          items:
  3861            type: "string"
  3862          example: ["img-authz-plugin", "hbm"]
  3863        Log:
  3864          description: "Names of available logging-drivers, and logging-driver plugins."
  3865          type: "array"
  3866          items:
  3867            type: "string"
  3868          example: ["awslogs", "fluentd", "gcplogs", "gelf", "journald", "json-file", "logentries", "splunk", "syslog"]
  3869  
  3870  
  3871    RegistryServiceConfig:
  3872      description: |
  3873        RegistryServiceConfig stores daemon registry services configuration.
  3874      type: "object"
  3875      x-nullable: true
  3876      properties:
  3877        AllowNondistributableArtifactsCIDRs:
  3878          description: |
  3879            List of IP ranges to which nondistributable artifacts can be pushed,
  3880            using the CIDR syntax [RFC 4632](https://tools.ietf.org/html/4632).
  3881  
  3882            Some images (for example, Windows base images) contain artifacts
  3883            whose distribution is restricted by license. When these images are
  3884            pushed to a registry, restricted artifacts are not included.
  3885  
  3886            This configuration override this behavior, and enables the daemon to
  3887            push nondistributable artifacts to all registries whose resolved IP
  3888            address is within the subnet described by the CIDR syntax.
  3889  
  3890            This option is useful when pushing images containing
  3891            nondistributable artifacts to a registry on an air-gapped network so
  3892            hosts on that network can pull the images without connecting to
  3893            another server.
  3894  
  3895            > **Warning**: Nondistributable artifacts typically have restrictions
  3896            > on how and where they can be distributed and shared. Only use this
  3897            > feature to push artifacts to private registries and ensure that you
  3898            > are in compliance with any terms that cover redistributing
  3899            > nondistributable artifacts.
  3900  
  3901          type: "array"
  3902          items:
  3903            type: "string"
  3904          example: ["::1/128", "127.0.0.0/8"]
  3905        AllowNondistributableArtifactsHostnames:
  3906          description: |
  3907            List of registry hostnames to which nondistributable artifacts can be
  3908            pushed, using the format `<hostname>[:<port>]` or `<IP address>[:<port>]`.
  3909  
  3910            Some images (for example, Windows base images) contain artifacts
  3911            whose distribution is restricted by license. When these images are
  3912            pushed to a registry, restricted artifacts are not included.
  3913  
  3914            This configuration override this behavior for the specified
  3915            registries.
  3916  
  3917            This option is useful when pushing images containing
  3918            nondistributable artifacts to a registry on an air-gapped network so
  3919            hosts on that network can pull the images without connecting to
  3920            another server.
  3921  
  3922            > **Warning**: Nondistributable artifacts typically have restrictions
  3923            > on how and where they can be distributed and shared. Only use this
  3924            > feature to push artifacts to private registries and ensure that you
  3925            > are in compliance with any terms that cover redistributing
  3926            > nondistributable artifacts.
  3927          type: "array"
  3928          items:
  3929            type: "string"
  3930          example: ["registry.internal.corp.example.com:3000", "[2001:db8:a0b:12f0::1]:443"]
  3931        InsecureRegistryCIDRs:
  3932          description: |
  3933            List of IP ranges of insecure registries, using the CIDR syntax
  3934            ([RFC 4632](https://tools.ietf.org/html/4632)). Insecure registries
  3935            accept un-encrypted (HTTP) and/or untrusted (HTTPS with certificates
  3936            from unknown CAs) communication.
  3937  
  3938            By default, local registries (`127.0.0.0/8`) are configured as
  3939            insecure. All other registries are secure. Communicating with an
  3940            insecure registry is not possible if the daemon assumes that registry
  3941            is secure.
  3942  
  3943            This configuration override this behavior, insecure communication with
  3944            registries whose resolved IP address is within the subnet described by
  3945            the CIDR syntax.
  3946  
  3947            Registries can also be marked insecure by hostname. Those registries
  3948            are listed under `IndexConfigs` and have their `Secure` field set to
  3949            `false`.
  3950  
  3951            > **Warning**: Using this option can be useful when running a local
  3952            > registry, but introduces security vulnerabilities. This option
  3953            > should therefore ONLY be used for testing purposes. For increased
  3954            > security, users should add their CA to their system's list of trusted
  3955            > CAs instead of enabling this option.
  3956          type: "array"
  3957          items:
  3958            type: "string"
  3959          example: ["::1/128", "127.0.0.0/8"]
  3960        IndexConfigs:
  3961          type: "object"
  3962          additionalProperties:
  3963            $ref: "#/definitions/IndexInfo"
  3964          example:
  3965            "127.0.0.1:5000":
  3966              "Name": "127.0.0.1:5000"
  3967              "Mirrors": []
  3968              "Secure": false
  3969              "Official": false
  3970            "[2001:db8:a0b:12f0::1]:80":
  3971              "Name": "[2001:db8:a0b:12f0::1]:80"
  3972              "Mirrors": []
  3973              "Secure": false
  3974              "Official": false
  3975            "docker.io":
  3976              Name: "docker.io"
  3977              Mirrors: ["https://hub-mirror.corp.example.com:5000/"]
  3978              Secure: true
  3979              Official: true
  3980            "registry.internal.corp.example.com:3000":
  3981              Name: "registry.internal.corp.example.com:3000"
  3982              Mirrors: []
  3983              Secure: false
  3984              Official: false
  3985        Mirrors:
  3986          description: |
  3987            List of registry URLs that act as a mirror for the official
  3988            (`docker.io`) registry.
  3989  
  3990          type: "array"
  3991          items:
  3992            type: "string"
  3993          example:
  3994            - "https://hub-mirror.corp.example.com:5000/"
  3995            - "https://[2001:db8:a0b:12f0::1]/"
  3996  
  3997    IndexInfo:
  3998      description:
  3999        IndexInfo contains information about a registry.
  4000      type: "object"
  4001      x-nullable: true
  4002      properties:
  4003        Name:
  4004          description: |
  4005            Name of the registry, such as "docker.io".
  4006          type: "string"
  4007          example: "docker.io"
  4008        Mirrors:
  4009          description: |
  4010            List of mirrors, expressed as URIs.
  4011          type: "array"
  4012          items:
  4013            type: "string"
  4014          example:
  4015            - "https://hub-mirror.corp.example.com:5000/"
  4016            - "https://registry-2.docker.io/"
  4017            - "https://registry-3.docker.io/"
  4018        Secure:
  4019          description: |
  4020            Indicates if the the registry is part of the list of insecure
  4021            registries.
  4022  
  4023            If `false`, the registry is insecure. Insecure registries accept
  4024            un-encrypted (HTTP) and/or untrusted (HTTPS with certificates from
  4025            unknown CAs) communication.
  4026  
  4027            > **Warning**: Insecure registries can be useful when running a local
  4028            > registry. However, because its use creates security vulnerabilities
  4029            > it should ONLY be enabled for testing purposes. For increased
  4030            > security, users should add their CA to their system's list of
  4031            > trusted CAs instead of enabling this option.
  4032          type: "boolean"
  4033          example: true
  4034        Official:
  4035          description: |
  4036            Indicates whether this is an official registry (i.e., Docker Hub / docker.io)
  4037          type: "boolean"
  4038          example: true
  4039  
  4040    Runtime:
  4041      description: |
  4042        Runtime describes an [OCI compliant](https://github.com/opencontainers/runtime-spec)
  4043        runtime.
  4044  
  4045        The runtime is invoked by the daemon via the `containerd` daemon. OCI
  4046        runtimes act as an interface to the Linux kernel namespaces, cgroups,
  4047        and SELinux.
  4048      type: "object"
  4049      properties:
  4050        path:
  4051          description: |
  4052            Name and, optional, path, of the OCI executable binary.
  4053  
  4054            If the path is omitted, the daemon searches the host's `$PATH` for the
  4055            binary and uses the first result.
  4056          type: "string"
  4057          example: "/usr/local/bin/my-oci-runtime"
  4058        runtimeArgs:
  4059          description: |
  4060            List of command-line arguments to pass to the runtime when invoked.
  4061          type: "array"
  4062          x-nullable: true
  4063          items:
  4064            type: "string"
  4065          example: ["--debug", "--systemd-cgroup=false"]
  4066  
  4067    Commit:
  4068      description: |
  4069        Commit holds the Git-commit (SHA1) that a binary was built from, as
  4070        reported in the version-string of external tools, such as `containerd`,
  4071        or `runC`.
  4072      type: "object"
  4073      properties:
  4074        ID:
  4075          description: "Actual commit ID of external tool."
  4076          type: "string"
  4077          example: "cfb82a876ecc11b5ca0977d1733adbe58599088a"
  4078        Expected:
  4079          description: |
  4080            Commit ID of external tool expected by dockerd as set at build time.
  4081          type: "string"
  4082          example: "2d41c047c83e09a6d61d464906feb2a2f3c52aa4"
  4083  
  4084    SwarmInfo:
  4085      description: |
  4086        Represents generic information about swarm.
  4087      type: "object"
  4088      properties:
  4089        NodeID:
  4090          description: "Unique identifier of for this node in the swarm."
  4091          type: "string"
  4092          default: ""
  4093          example: "k67qz4598weg5unwwffg6z1m1"
  4094        NodeAddr:
  4095          description: |
  4096            IP address at which this node can be reached by other nodes in the
  4097            swarm.
  4098          type: "string"
  4099          default: ""
  4100          example: "10.0.0.46"
  4101        LocalNodeState:
  4102          $ref: "#/definitions/LocalNodeState"
  4103        ControlAvailable:
  4104          type: "boolean"
  4105          default: false
  4106          example: true
  4107        Error:
  4108          type: "string"
  4109          default: ""
  4110        RemoteManagers:
  4111          description: |
  4112            List of ID's and addresses of other managers in the swarm.
  4113          type: "array"
  4114          default: null
  4115          x-nullable: true
  4116          items:
  4117            $ref: "#/definitions/PeerNode"
  4118          example:
  4119            - NodeID: "71izy0goik036k48jg985xnds"
  4120              Addr: "10.0.0.158:2377"
  4121            - NodeID: "79y6h1o4gv8n120drcprv5nmc"
  4122              Addr: "10.0.0.159:2377"
  4123            - NodeID: "k67qz4598weg5unwwffg6z1m1"
  4124              Addr: "10.0.0.46:2377"
  4125        Nodes:
  4126          description: "Total number of nodes in the swarm."
  4127          type: "integer"
  4128          x-nullable: true
  4129          example: 4
  4130        Managers:
  4131          description: "Total number of managers in the swarm."
  4132          type: "integer"
  4133          x-nullable: true
  4134          example: 3
  4135        Cluster:
  4136          $ref: "#/definitions/ClusterInfo"
  4137  
  4138    LocalNodeState:
  4139      description: "Current local status of this node."
  4140      type: "string"
  4141      default: ""
  4142      enum:
  4143        - ""
  4144        - "inactive"
  4145        - "pending"
  4146        - "active"
  4147        - "error"
  4148        - "locked"
  4149      example: "active"
  4150  
  4151    PeerNode:
  4152      description: "Represents a peer-node in the swarm"
  4153      properties:
  4154        NodeID:
  4155          description: "Unique identifier of for this node in the swarm."
  4156          type: "string"
  4157        Addr:
  4158          description: |
  4159            IP address and ports at which this node can be reached.
  4160          type: "string"
  4161  
  4162  paths:
  4163    /containers/json:
  4164      get:
  4165        summary: "List containers"
  4166        description: |
  4167          Returns a list of containers. For details on the format, see [the inspect endpoint](#operation/ContainerInspect).
  4168  
  4169          Note that it uses a different, smaller representation of a container than inspecting a single container. For example,
  4170          the list of linked containers is not propagated .
  4171        operationId: "ContainerList"
  4172        produces:
  4173          - "application/json"
  4174        parameters:
  4175          - name: "all"
  4176            in: "query"
  4177            description: "Return all containers. By default, only running containers are shown"
  4178            type: "boolean"
  4179            default: false
  4180          - name: "limit"
  4181            in: "query"
  4182            description: "Return this number of most recently created containers, including non-running ones."
  4183            type: "integer"
  4184          - name: "size"
  4185            in: "query"
  4186            description: "Return the size of container as fields `SizeRw` and `SizeRootFs`."
  4187            type: "boolean"
  4188            default: false
  4189          - name: "filters"
  4190            in: "query"
  4191            description: |
  4192              Filters to process on the container list, encoded as JSON (a `map[string][]string`). For example, `{"status": ["paused"]}` will only return paused containers. Available filters:
  4193  
  4194              - `ancestor`=(`<image-name>[:<tag>]`, `<image id>`, or `<image@digest>`)
  4195              - `before`=(`<container id>` or `<container name>`)
  4196              - `expose`=(`<port>[/<proto>]`|`<startport-endport>/[<proto>]`)
  4197              - `exited=<int>` containers with exit code of `<int>`
  4198              - `health`=(`starting`|`healthy`|`unhealthy`|`none`)
  4199              - `id=<ID>` a container's ID
  4200              - `isolation=`(`default`|`process`|`hyperv`) (Windows daemon only)
  4201              - `is-task=`(`true`|`false`)
  4202              - `label=key` or `label="key=value"` of a container label
  4203              - `name=<name>` a container's name
  4204              - `network`=(`<network id>` or `<network name>`)
  4205              - `publish`=(`<port>[/<proto>]`|`<startport-endport>/[<proto>]`)
  4206              - `since`=(`<container id>` or `<container name>`)
  4207              - `status=`(`created`|`restarting`|`running`|`removing`|`paused`|`exited`|`dead`)
  4208              - `volume`=(`<volume name>` or `<mount point destination>`)
  4209            type: "string"
  4210        responses:
  4211          200:
  4212            description: "no error"
  4213            schema:
  4214              $ref: "#/definitions/ContainerSummary"
  4215            examples:
  4216              application/json:
  4217                - Id: "8dfafdbc3a40"
  4218                  Names:
  4219                    - "/boring_feynman"
  4220                  Image: "ubuntu:latest"
  4221                  ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82"
  4222                  Command: "echo 1"
  4223                  Created: 1367854155
  4224                  State: "Exited"
  4225                  Status: "Exit 0"
  4226                  Ports:
  4227                    - PrivatePort: 2222
  4228                      PublicPort: 3333
  4229                      Type: "tcp"
  4230                  Labels:
  4231                    com.example.vendor: "Acme"
  4232                    com.example.license: "GPL"
  4233                    com.example.version: "1.0"
  4234                  SizeRw: 12288
  4235                  SizeRootFs: 0
  4236                  HostConfig:
  4237                    NetworkMode: "default"
  4238                  NetworkSettings:
  4239                    Networks:
  4240                      bridge:
  4241                        NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  4242                        EndpointID: "2cdc4edb1ded3631c81f57966563e5c8525b81121bb3706a9a9a3ae102711f3f"
  4243                        Gateway: "172.17.0.1"
  4244                        IPAddress: "172.17.0.2"
  4245                        IPPrefixLen: 16
  4246                        IPv6Gateway: ""
  4247                        GlobalIPv6Address: ""
  4248                        GlobalIPv6PrefixLen: 0
  4249                        MacAddress: "02:42:ac:11:00:02"
  4250                  Mounts:
  4251                    - Name: "fac362...80535"
  4252                      Source: "/data"
  4253                      Destination: "/data"
  4254                      Driver: "local"
  4255                      Mode: "ro,Z"
  4256                      RW: false
  4257                      Propagation: ""
  4258                - Id: "9cd87474be90"
  4259                  Names:
  4260                    - "/coolName"
  4261                  Image: "ubuntu:latest"
  4262                  ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82"
  4263                  Command: "echo 222222"
  4264                  Created: 1367854155
  4265                  State: "Exited"
  4266                  Status: "Exit 0"
  4267                  Ports: []
  4268                  Labels: {}
  4269                  SizeRw: 12288
  4270                  SizeRootFs: 0
  4271                  HostConfig:
  4272                    NetworkMode: "default"
  4273                  NetworkSettings:
  4274                    Networks:
  4275                      bridge:
  4276                        NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  4277                        EndpointID: "88eaed7b37b38c2a3f0c4bc796494fdf51b270c2d22656412a2ca5d559a64d7a"
  4278                        Gateway: "172.17.0.1"
  4279                        IPAddress: "172.17.0.8"
  4280                        IPPrefixLen: 16
  4281                        IPv6Gateway: ""
  4282                        GlobalIPv6Address: ""
  4283                        GlobalIPv6PrefixLen: 0
  4284                        MacAddress: "02:42:ac:11:00:08"
  4285                  Mounts: []
  4286                - Id: "3176a2479c92"
  4287                  Names:
  4288                    - "/sleepy_dog"
  4289                  Image: "ubuntu:latest"
  4290                  ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82"
  4291                  Command: "echo 3333333333333333"
  4292                  Created: 1367854154
  4293                  State: "Exited"
  4294                  Status: "Exit 0"
  4295                  Ports: []
  4296                  Labels: {}
  4297                  SizeRw: 12288
  4298                  SizeRootFs: 0
  4299                  HostConfig:
  4300                    NetworkMode: "default"
  4301                  NetworkSettings:
  4302                    Networks:
  4303                      bridge:
  4304                        NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  4305                        EndpointID: "8b27c041c30326d59cd6e6f510d4f8d1d570a228466f956edf7815508f78e30d"
  4306                        Gateway: "172.17.0.1"
  4307                        IPAddress: "172.17.0.6"
  4308                        IPPrefixLen: 16
  4309                        IPv6Gateway: ""
  4310                        GlobalIPv6Address: ""
  4311                        GlobalIPv6PrefixLen: 0
  4312                        MacAddress: "02:42:ac:11:00:06"
  4313                  Mounts: []
  4314                - Id: "4cb07b47f9fb"
  4315                  Names:
  4316                    - "/running_cat"
  4317                  Image: "ubuntu:latest"
  4318                  ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82"
  4319                  Command: "echo 444444444444444444444444444444444"
  4320                  Created: 1367854152
  4321                  State: "Exited"
  4322                  Status: "Exit 0"
  4323                  Ports: []
  4324                  Labels: {}
  4325                  SizeRw: 12288
  4326                  SizeRootFs: 0
  4327                  HostConfig:
  4328                    NetworkMode: "default"
  4329                  NetworkSettings:
  4330                    Networks:
  4331                      bridge:
  4332                        NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  4333                        EndpointID: "d91c7b2f0644403d7ef3095985ea0e2370325cd2332ff3a3225c4247328e66e9"
  4334                        Gateway: "172.17.0.1"
  4335                        IPAddress: "172.17.0.5"
  4336                        IPPrefixLen: 16
  4337                        IPv6Gateway: ""
  4338                        GlobalIPv6Address: ""
  4339                        GlobalIPv6PrefixLen: 0
  4340                        MacAddress: "02:42:ac:11:00:05"
  4341                  Mounts: []
  4342          400:
  4343            description: "bad parameter"
  4344            schema:
  4345              $ref: "#/definitions/ErrorResponse"
  4346          500:
  4347            description: "server error"
  4348            schema:
  4349              $ref: "#/definitions/ErrorResponse"
  4350        tags: ["Container"]
  4351    /containers/create:
  4352      post:
  4353        summary: "Create a container"
  4354        operationId: "ContainerCreate"
  4355        consumes:
  4356          - "application/json"
  4357          - "application/octet-stream"
  4358        produces:
  4359          - "application/json"
  4360        parameters:
  4361          - name: "name"
  4362            in: "query"
  4363            description: "Assign the specified name to the container. Must match `/?[a-zA-Z0-9_-]+`."
  4364            type: "string"
  4365            pattern: "/?[a-zA-Z0-9_-]+"
  4366          - name: "body"
  4367            in: "body"
  4368            description: "Container to create"
  4369            schema:
  4370              allOf:
  4371                - $ref: "#/definitions/ContainerConfig"
  4372                - type: "object"
  4373                  properties:
  4374                    HostConfig:
  4375                      $ref: "#/definitions/HostConfig"
  4376                    NetworkingConfig:
  4377                      description: "This container's networking configuration."
  4378                      type: "object"
  4379                      properties:
  4380                        EndpointsConfig:
  4381                          description: "A mapping of network name to endpoint configuration for that network."
  4382                          type: "object"
  4383                          additionalProperties:
  4384                            $ref: "#/definitions/EndpointSettings"
  4385              example:
  4386                Hostname: ""
  4387                Domainname: ""
  4388                User: ""
  4389                AttachStdin: false
  4390                AttachStdout: true
  4391                AttachStderr: true
  4392                Tty: false
  4393                OpenStdin: false
  4394                StdinOnce: false
  4395                Env:
  4396                  - "FOO=bar"
  4397                  - "BAZ=quux"
  4398                Cmd:
  4399                  - "date"
  4400                Entrypoint: ""
  4401                Image: "ubuntu"
  4402                Labels:
  4403                  com.example.vendor: "Acme"
  4404                  com.example.license: "GPL"
  4405                  com.example.version: "1.0"
  4406                Volumes:
  4407                  /volumes/data: {}
  4408                WorkingDir: ""
  4409                NetworkDisabled: false
  4410                MacAddress: "12:34:56:78:9a:bc"
  4411                ExposedPorts:
  4412                  22/tcp: {}
  4413                StopSignal: "SIGTERM"
  4414                StopTimeout: 10
  4415                HostConfig:
  4416                  Binds:
  4417                    - "/tmp:/tmp"
  4418                  Links:
  4419                    - "redis3:redis"
  4420                  Memory: 0
  4421                  MemorySwap: 0
  4422                  MemoryReservation: 0
  4423                  KernelMemory: 0
  4424                  NanoCPUs: 500000
  4425                  CpuPercent: 80
  4426                  CpuShares: 512
  4427                  CpuPeriod: 100000
  4428                  CpuRealtimePeriod: 1000000
  4429                  CpuRealtimeRuntime: 10000
  4430                  CpuQuota: 50000
  4431                  CpusetCpus: "0,1"
  4432                  CpusetMems: "0,1"
  4433                  MaximumIOps: 0
  4434                  MaximumIOBps: 0
  4435                  BlkioWeight: 300
  4436                  BlkioWeightDevice:
  4437                    - {}
  4438                  BlkioDeviceReadBps:
  4439                    - {}
  4440                  BlkioDeviceReadIOps:
  4441                    - {}
  4442                  BlkioDeviceWriteBps:
  4443                    - {}
  4444                  BlkioDeviceWriteIOps:
  4445                    - {}
  4446                  MemorySwappiness: 60
  4447                  OomKillDisable: false
  4448                  OomScoreAdj: 500
  4449                  PidMode: ""
  4450                  PidsLimit: -1
  4451                  PortBindings:
  4452                    22/tcp:
  4453                      - HostPort: "11022"
  4454                  PublishAllPorts: false
  4455                  Privileged: false
  4456                  ReadonlyRootfs: false
  4457                  Dns:
  4458                    - "8.8.8.8"
  4459                  DnsOptions:
  4460                    - ""
  4461                  DnsSearch:
  4462                    - ""
  4463                  VolumesFrom:
  4464                    - "parent"
  4465                    - "other:ro"
  4466                  CapAdd:
  4467                    - "NET_ADMIN"
  4468                  CapDrop:
  4469                    - "MKNOD"
  4470                  GroupAdd:
  4471                    - "newgroup"
  4472                  RestartPolicy:
  4473                    Name: ""
  4474                    MaximumRetryCount: 0
  4475                  AutoRemove: true
  4476                  NetworkMode: "bridge"
  4477                  Devices: []
  4478                  Ulimits:
  4479                    - {}
  4480                  LogConfig:
  4481                    Type: "json-file"
  4482                    Config: {}
  4483                  SecurityOpt: []
  4484                  StorageOpt: {}
  4485                  CgroupParent: ""
  4486                  VolumeDriver: ""
  4487                  ShmSize: 67108864
  4488                NetworkingConfig:
  4489                  EndpointsConfig:
  4490                    isolated_nw:
  4491                      IPAMConfig:
  4492                        IPv4Address: "172.20.30.33"
  4493                        IPv6Address: "2001:db8:abcd::3033"
  4494                        LinkLocalIPs:
  4495                          - "169.254.34.68"
  4496                          - "fe80::3468"
  4497                      Links:
  4498                        - "container_1"
  4499                        - "container_2"
  4500                      Aliases:
  4501                        - "server_x"
  4502                        - "server_y"
  4503  
  4504            required: true
  4505        responses:
  4506          201:
  4507            description: "Container created successfully"
  4508            schema:
  4509              type: "object"
  4510              required: [Id, Warnings]
  4511              properties:
  4512                Id:
  4513                  description: "The ID of the created container"
  4514                  type: "string"
  4515                  x-nullable: false
  4516                Warnings:
  4517                  description: "Warnings encountered when creating the container"
  4518                  type: "array"
  4519                  x-nullable: false
  4520                  items:
  4521                    type: "string"
  4522            examples:
  4523              application/json:
  4524                Id: "e90e34656806"
  4525                Warnings: []
  4526          400:
  4527            description: "bad parameter"
  4528            schema:
  4529              $ref: "#/definitions/ErrorResponse"
  4530          404:
  4531            description: "no such container"
  4532            schema:
  4533              $ref: "#/definitions/ErrorResponse"
  4534            examples:
  4535              application/json:
  4536                message: "No such container: c2ada9df5af8"
  4537          409:
  4538            description: "conflict"
  4539            schema:
  4540              $ref: "#/definitions/ErrorResponse"
  4541          500:
  4542            description: "server error"
  4543            schema:
  4544              $ref: "#/definitions/ErrorResponse"
  4545        tags: ["Container"]
  4546    /containers/{id}/json:
  4547      get:
  4548        summary: "Inspect a container"
  4549        description: "Return low-level information about a container."
  4550        operationId: "ContainerInspect"
  4551        produces:
  4552          - "application/json"
  4553        responses:
  4554          200:
  4555            description: "no error"
  4556            schema:
  4557              type: "object"
  4558              properties:
  4559                Id:
  4560                  description: "The ID of the container"
  4561                  type: "string"
  4562                Created:
  4563                  description: "The time the container was created"
  4564                  type: "string"
  4565                Path:
  4566                  description: "The path to the command being run"
  4567                  type: "string"
  4568                Args:
  4569                  description: "The arguments to the command being run"
  4570                  type: "array"
  4571                  items:
  4572                    type: "string"
  4573                State:
  4574                  description: "The state of the container."
  4575                  type: "object"
  4576                  properties:
  4577                    Status:
  4578                      description: |
  4579                        The status of the container. For example, `"running"` or `"exited"`.
  4580                      type: "string"
  4581                      enum: ["created", "running", "paused", "restarting", "removing", "exited", "dead"]
  4582                    Running:
  4583                      description: |
  4584                        Whether this container is running.
  4585  
  4586                        Note that a running container can be _paused_. The `Running` and `Paused`
  4587                        booleans are not mutually exclusive:
  4588  
  4589                        When pausing a container (on Linux), the cgroups freezer is used to suspend
  4590                        all processes in the container. Freezing the process requires the process to
  4591                        be running. As a result, paused containers are both `Running` _and_ `Paused`.
  4592  
  4593                        Use the `Status` field instead to determine if a container's state is "running".
  4594                      type: "boolean"
  4595                    Paused:
  4596                      description: "Whether this container is paused."
  4597                      type: "boolean"
  4598                    Restarting:
  4599                      description: "Whether this container is restarting."
  4600                      type: "boolean"
  4601                    OOMKilled:
  4602                      description: "Whether this container has been killed because it ran out of memory."
  4603                      type: "boolean"
  4604                    Dead:
  4605                      type: "boolean"
  4606                    Pid:
  4607                      description: "The process ID of this container"
  4608                      type: "integer"
  4609                    ExitCode:
  4610                      description: "The last exit code of this container"
  4611                      type: "integer"
  4612                    Error:
  4613                      type: "string"
  4614                    StartedAt:
  4615                      description: "The time when this container was last started."
  4616                      type: "string"
  4617                    FinishedAt:
  4618                      description: "The time when this container last exited."
  4619                      type: "string"
  4620                Image:
  4621                  description: "The container's image"
  4622                  type: "string"
  4623                ResolvConfPath:
  4624                  type: "string"
  4625                HostnamePath:
  4626                  type: "string"
  4627                HostsPath:
  4628                  type: "string"
  4629                LogPath:
  4630                  type: "string"
  4631                Node:
  4632                  description: "TODO"
  4633                  type: "object"
  4634                Name:
  4635                  type: "string"
  4636                RestartCount:
  4637                  type: "integer"
  4638                Driver:
  4639                  type: "string"
  4640                MountLabel:
  4641                  type: "string"
  4642                ProcessLabel:
  4643                  type: "string"
  4644                AppArmorProfile:
  4645                  type: "string"
  4646                ExecIDs:
  4647                  type: "string"
  4648                HostConfig:
  4649                  $ref: "#/definitions/HostConfig"
  4650                GraphDriver:
  4651                  $ref: "#/definitions/GraphDriverData"
  4652                SizeRw:
  4653                  description: "The size of files that have been created or changed by this container."
  4654                  type: "integer"
  4655                  format: "int64"
  4656                SizeRootFs:
  4657                  description: "The total size of all the files in this container."
  4658                  type: "integer"
  4659                  format: "int64"
  4660                Mounts:
  4661                  type: "array"
  4662                  items:
  4663                    $ref: "#/definitions/MountPoint"
  4664                Config:
  4665                  $ref: "#/definitions/ContainerConfig"
  4666                NetworkSettings:
  4667                  $ref: "#/definitions/NetworkSettings"
  4668            examples:
  4669              application/json:
  4670                AppArmorProfile: ""
  4671                Args:
  4672                  - "-c"
  4673                  - "exit 9"
  4674                Config:
  4675                  AttachStderr: true
  4676                  AttachStdin: false
  4677                  AttachStdout: true
  4678                  Cmd:
  4679                    - "/bin/sh"
  4680                    - "-c"
  4681                    - "exit 9"
  4682                  Domainname: ""
  4683                  Env:
  4684                    - "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
  4685                  Hostname: "ba033ac44011"
  4686                  Image: "ubuntu"
  4687                  Labels:
  4688                    com.example.vendor: "Acme"
  4689                    com.example.license: "GPL"
  4690                    com.example.version: "1.0"
  4691                  MacAddress: ""
  4692                  NetworkDisabled: false
  4693                  OpenStdin: false
  4694                  StdinOnce: false
  4695                  Tty: false
  4696                  User: ""
  4697                  Volumes:
  4698                    /volumes/data: {}
  4699                  WorkingDir: ""
  4700                  StopSignal: "SIGTERM"
  4701                  StopTimeout: 10
  4702                Created: "2015-01-06T15:47:31.485331387Z"
  4703                Driver: "devicemapper"
  4704                HostConfig:
  4705                  MaximumIOps: 0
  4706                  MaximumIOBps: 0
  4707                  BlkioWeight: 0
  4708                  BlkioWeightDevice:
  4709                    - {}
  4710                  BlkioDeviceReadBps:
  4711                    - {}
  4712                  BlkioDeviceWriteBps:
  4713                    - {}
  4714                  BlkioDeviceReadIOps:
  4715                    - {}
  4716                  BlkioDeviceWriteIOps:
  4717                    - {}
  4718                  ContainerIDFile: ""
  4719                  CpusetCpus: ""
  4720                  CpusetMems: ""
  4721                  CpuPercent: 80
  4722                  CpuShares: 0
  4723                  CpuPeriod: 100000
  4724                  CpuRealtimePeriod: 1000000
  4725                  CpuRealtimeRuntime: 10000
  4726                  Devices: []
  4727                  IpcMode: ""
  4728                  LxcConf: []
  4729                  Memory: 0
  4730                  MemorySwap: 0
  4731                  MemoryReservation: 0
  4732                  KernelMemory: 0
  4733                  OomKillDisable: false
  4734                  OomScoreAdj: 500
  4735                  NetworkMode: "bridge"
  4736                  PidMode: ""
  4737                  PortBindings: {}
  4738                  Privileged: false
  4739                  ReadonlyRootfs: false
  4740                  PublishAllPorts: false
  4741                  RestartPolicy:
  4742                    MaximumRetryCount: 2
  4743                    Name: "on-failure"
  4744                  LogConfig:
  4745                    Type: "json-file"
  4746                  Sysctls:
  4747                    net.ipv4.ip_forward: "1"
  4748                  Ulimits:
  4749                    - {}
  4750                  VolumeDriver: ""
  4751                  ShmSize: 67108864
  4752                HostnamePath: "/var/lib/docker/containers/ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39/hostname"
  4753                HostsPath: "/var/lib/docker/containers/ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39/hosts"
  4754                LogPath: "/var/lib/docker/containers/1eb5fabf5a03807136561b3c00adcd2992b535d624d5e18b6cdc6a6844d9767b/1eb5fabf5a03807136561b3c00adcd2992b535d624d5e18b6cdc6a6844d9767b-json.log"
  4755                Id: "ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39"
  4756                Image: "04c5d3b7b0656168630d3ba35d8889bd0e9caafcaeb3004d2bfbc47e7c5d35d2"
  4757                MountLabel: ""
  4758                Name: "/boring_euclid"
  4759                NetworkSettings:
  4760                  Bridge: ""
  4761                  SandboxID: ""
  4762                  HairpinMode: false
  4763                  LinkLocalIPv6Address: ""
  4764                  LinkLocalIPv6PrefixLen: 0
  4765                  SandboxKey: ""
  4766                  EndpointID: ""
  4767                  Gateway: ""
  4768                  GlobalIPv6Address: ""
  4769                  GlobalIPv6PrefixLen: 0
  4770                  IPAddress: ""
  4771                  IPPrefixLen: 0
  4772                  IPv6Gateway: ""
  4773                  MacAddress: ""
  4774                  Networks:
  4775                    bridge:
  4776                      NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  4777                      EndpointID: "7587b82f0dada3656fda26588aee72630c6fab1536d36e394b2bfbcf898c971d"
  4778                      Gateway: "172.17.0.1"
  4779                      IPAddress: "172.17.0.2"
  4780                      IPPrefixLen: 16
  4781                      IPv6Gateway: ""
  4782                      GlobalIPv6Address: ""
  4783                      GlobalIPv6PrefixLen: 0
  4784                      MacAddress: "02:42:ac:12:00:02"
  4785                Path: "/bin/sh"
  4786                ProcessLabel: ""
  4787                ResolvConfPath: "/var/lib/docker/containers/ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39/resolv.conf"
  4788                RestartCount: 1
  4789                State:
  4790                  Error: ""
  4791                  ExitCode: 9
  4792                  FinishedAt: "2015-01-06T15:47:32.080254511Z"
  4793                  OOMKilled: false
  4794                  Dead: false
  4795                  Paused: false
  4796                  Pid: 0
  4797                  Restarting: false
  4798                  Running: true
  4799                  StartedAt: "2015-01-06T15:47:32.072697474Z"
  4800                  Status: "running"
  4801                Mounts:
  4802                  - Name: "fac362...80535"
  4803                    Source: "/data"
  4804                    Destination: "/data"
  4805                    Driver: "local"
  4806                    Mode: "ro,Z"
  4807                    RW: false
  4808                    Propagation: ""
  4809          404:
  4810            description: "no such container"
  4811            schema:
  4812              $ref: "#/definitions/ErrorResponse"
  4813            examples:
  4814              application/json:
  4815                message: "No such container: c2ada9df5af8"
  4816          500:
  4817            description: "server error"
  4818            schema:
  4819              $ref: "#/definitions/ErrorResponse"
  4820        parameters:
  4821          - name: "id"
  4822            in: "path"
  4823            required: true
  4824            description: "ID or name of the container"
  4825            type: "string"
  4826          - name: "size"
  4827            in: "query"
  4828            type: "boolean"
  4829            default: false
  4830            description: "Return the size of container as fields `SizeRw` and `SizeRootFs`"
  4831        tags: ["Container"]
  4832    /containers/{id}/top:
  4833      get:
  4834        summary: "List processes running inside a container"
  4835        description: "On Unix systems, this is done by running the `ps` command. This endpoint is not supported on Windows."
  4836        operationId: "ContainerTop"
  4837        responses:
  4838          200:
  4839            description: "no error"
  4840            schema:
  4841              type: "object"
  4842              properties:
  4843                Titles:
  4844                  description: "The ps column titles"
  4845                  type: "array"
  4846                  items:
  4847                    type: "string"
  4848                Processes:
  4849                  description: "Each process running in the container, where each is process is an array of values corresponding to the titles"
  4850                  type: "array"
  4851                  items:
  4852                    type: "array"
  4853                    items:
  4854                      type: "string"
  4855            examples:
  4856              application/json:
  4857                Titles:
  4858                  - "UID"
  4859                  - "PID"
  4860                  - "PPID"
  4861                  - "C"
  4862                  - "STIME"
  4863                  - "TTY"
  4864                  - "TIME"
  4865                  - "CMD"
  4866                Processes:
  4867                  -
  4868                    - "root"
  4869                    - "13642"
  4870                    - "882"
  4871                    - "0"
  4872                    - "17:03"
  4873                    - "pts/0"
  4874                    - "00:00:00"
  4875                    - "/bin/bash"
  4876                  -
  4877                    - "root"
  4878                    - "13735"
  4879                    - "13642"
  4880                    - "0"
  4881                    - "17:06"
  4882                    - "pts/0"
  4883                    - "00:00:00"
  4884                    - "sleep 10"
  4885          404:
  4886            description: "no such container"
  4887            schema:
  4888              $ref: "#/definitions/ErrorResponse"
  4889            examples:
  4890              application/json:
  4891                message: "No such container: c2ada9df5af8"
  4892          500:
  4893            description: "server error"
  4894            schema:
  4895              $ref: "#/definitions/ErrorResponse"
  4896        parameters:
  4897          - name: "id"
  4898            in: "path"
  4899            required: true
  4900            description: "ID or name of the container"
  4901            type: "string"
  4902          - name: "ps_args"
  4903            in: "query"
  4904            description: "The arguments to pass to `ps`. For example, `aux`"
  4905            type: "string"
  4906            default: "-ef"
  4907        tags: ["Container"]
  4908    /containers/{id}/logs:
  4909      get:
  4910        summary: "Get container logs"
  4911        description: |
  4912          Get `stdout` and `stderr` logs from a container.
  4913  
  4914          Note: This endpoint works only for containers with the `json-file` or `journald` logging driver.
  4915        operationId: "ContainerLogs"
  4916        responses:
  4917          101:
  4918            description: "logs returned as a stream"
  4919            schema:
  4920              type: "string"
  4921              format: "binary"
  4922          200:
  4923            description: "logs returned as a string in response body"
  4924            schema:
  4925              type: "string"
  4926          404:
  4927            description: "no such container"
  4928            schema:
  4929              $ref: "#/definitions/ErrorResponse"
  4930            examples:
  4931              application/json:
  4932                message: "No such container: c2ada9df5af8"
  4933          500:
  4934            description: "server error"
  4935            schema:
  4936              $ref: "#/definitions/ErrorResponse"
  4937        parameters:
  4938          - name: "id"
  4939            in: "path"
  4940            required: true
  4941            description: "ID or name of the container"
  4942            type: "string"
  4943          - name: "follow"
  4944            in: "query"
  4945            description: |
  4946              Return the logs as a stream.
  4947  
  4948              This will return a `101` HTTP response with a `Connection: upgrade` header, then hijack the HTTP connection to send raw output. For more information about hijacking and the stream format, [see the documentation for the attach endpoint](#operation/ContainerAttach).
  4949            type: "boolean"
  4950            default: false
  4951          - name: "stdout"
  4952            in: "query"
  4953            description: "Return logs from `stdout`"
  4954            type: "boolean"
  4955            default: false
  4956          - name: "stderr"
  4957            in: "query"
  4958            description: "Return logs from `stderr`"
  4959            type: "boolean"
  4960            default: false
  4961          - name: "since"
  4962            in: "query"
  4963            description: "Only return logs since this time, as a UNIX timestamp"
  4964            type: "integer"
  4965            default: 0
  4966          - name: "timestamps"
  4967            in: "query"
  4968            description: "Add timestamps to every log line"
  4969            type: "boolean"
  4970            default: false
  4971          - name: "tail"
  4972            in: "query"
  4973            description: "Only return this number of log lines from the end of the logs. Specify as an integer or `all` to output all log lines."
  4974            type: "string"
  4975            default: "all"
  4976        tags: ["Container"]
  4977    /containers/{id}/changes:
  4978      get:
  4979        summary: "Get changes on a container’s filesystem"
  4980        description: |
  4981          Returns which files in a container's filesystem have been added, deleted,
  4982          or modified. The `Kind` of modification can be one of:
  4983  
  4984          - `0`: Modified
  4985          - `1`: Added
  4986          - `2`: Deleted
  4987        operationId: "ContainerChanges"
  4988        produces: ["application/json"]
  4989        responses:
  4990          200:
  4991            description: "The list of changes"
  4992            schema:
  4993              type: "array"
  4994              items:
  4995                type: "object"
  4996                x-go-name: "ContainerChangeResponseItem"
  4997                required: [Path, Kind]
  4998                properties:
  4999                  Path:
  5000                    description: "Path to file that has changed"
  5001                    type: "string"
  5002                    x-nullable: false
  5003                  Kind:
  5004                    description: "Kind of change"
  5005                    type: "integer"
  5006                    format: "uint8"
  5007                    enum: [0, 1, 2]
  5008                    x-nullable: false
  5009            examples:
  5010              application/json:
  5011                - Path: "/dev"
  5012                  Kind: 0
  5013                - Path: "/dev/kmsg"
  5014                  Kind: 1
  5015                - Path: "/test"
  5016                  Kind: 1
  5017          404:
  5018            description: "no such container"
  5019            schema:
  5020              $ref: "#/definitions/ErrorResponse"
  5021            examples:
  5022              application/json:
  5023                message: "No such container: c2ada9df5af8"
  5024          500:
  5025            description: "server error"
  5026            schema:
  5027              $ref: "#/definitions/ErrorResponse"
  5028        parameters:
  5029          - name: "id"
  5030            in: "path"
  5031            required: true
  5032            description: "ID or name of the container"
  5033            type: "string"
  5034        tags: ["Container"]
  5035    /containers/{id}/export:
  5036      get:
  5037        summary: "Export a container"
  5038        description: "Export the contents of a container as a tarball."
  5039        operationId: "ContainerExport"
  5040        produces:
  5041          - "application/octet-stream"
  5042        responses:
  5043          200:
  5044            description: "no error"
  5045          404:
  5046            description: "no such container"
  5047            schema:
  5048              $ref: "#/definitions/ErrorResponse"
  5049            examples:
  5050              application/json:
  5051                message: "No such container: c2ada9df5af8"
  5052          500:
  5053            description: "server error"
  5054            schema:
  5055              $ref: "#/definitions/ErrorResponse"
  5056        parameters:
  5057          - name: "id"
  5058            in: "path"
  5059            required: true
  5060            description: "ID or name of the container"
  5061            type: "string"
  5062        tags: ["Container"]
  5063    /containers/{id}/stats:
  5064      get:
  5065        summary: "Get container stats based on resource usage"
  5066        description: |
  5067          This endpoint returns a live stream of a container’s resource usage
  5068          statistics.
  5069  
  5070          The `precpu_stats` is the CPU statistic of last read, which is used
  5071          for calculating the CPU usage percentage. It is not the same as the
  5072          `cpu_stats` field.
  5073  
  5074          If either `precpu_stats.online_cpus` or `cpu_stats.online_cpus` is
  5075          nil then for compatibility with older daemons the length of the
  5076          corresponding `cpu_usage.percpu_usage` array should be used.
  5077        operationId: "ContainerStats"
  5078        produces: ["application/json"]
  5079        responses:
  5080          200:
  5081            description: "no error"
  5082            schema:
  5083              type: "object"
  5084            examples:
  5085              application/json:
  5086                read: "2015-01-08T22:57:31.547920715Z"
  5087                pids_stats:
  5088                  current: 3
  5089                networks:
  5090                  eth0:
  5091                    rx_bytes: 5338
  5092                    rx_dropped: 0
  5093                    rx_errors: 0
  5094                    rx_packets: 36
  5095                    tx_bytes: 648
  5096                    tx_dropped: 0
  5097                    tx_errors: 0
  5098                    tx_packets: 8
  5099                  eth5:
  5100                    rx_bytes: 4641
  5101                    rx_dropped: 0
  5102                    rx_errors: 0
  5103                    rx_packets: 26
  5104                    tx_bytes: 690
  5105                    tx_dropped: 0
  5106                    tx_errors: 0
  5107                    tx_packets: 9
  5108                memory_stats:
  5109                  stats:
  5110                    total_pgmajfault: 0
  5111                    cache: 0
  5112                    mapped_file: 0
  5113                    total_inactive_file: 0
  5114                    pgpgout: 414
  5115                    rss: 6537216
  5116                    total_mapped_file: 0
  5117                    writeback: 0
  5118                    unevictable: 0
  5119                    pgpgin: 477
  5120                    total_unevictable: 0
  5121                    pgmajfault: 0
  5122                    total_rss: 6537216
  5123                    total_rss_huge: 6291456
  5124                    total_writeback: 0
  5125                    total_inactive_anon: 0
  5126                    rss_huge: 6291456
  5127                    hierarchical_memory_limit: 67108864
  5128                    total_pgfault: 964
  5129                    total_active_file: 0
  5130                    active_anon: 6537216
  5131                    total_active_anon: 6537216
  5132                    total_pgpgout: 414
  5133                    total_cache: 0
  5134                    inactive_anon: 0
  5135                    active_file: 0
  5136                    pgfault: 964
  5137                    inactive_file: 0
  5138                    total_pgpgin: 477
  5139                  max_usage: 6651904
  5140                  usage: 6537216
  5141                  failcnt: 0
  5142                  limit: 67108864
  5143                blkio_stats: {}
  5144                cpu_stats:
  5145                  cpu_usage:
  5146                    percpu_usage:
  5147                      - 8646879
  5148                      - 24472255
  5149                      - 36438778
  5150                      - 30657443
  5151                    usage_in_usermode: 50000000
  5152                    total_usage: 100215355
  5153                    usage_in_kernelmode: 30000000
  5154                  system_cpu_usage: 739306590000000
  5155                  online_cpus: 4
  5156                  throttling_data:
  5157                    periods: 0
  5158                    throttled_periods: 0
  5159                    throttled_time: 0
  5160                precpu_stats:
  5161                  cpu_usage:
  5162                    percpu_usage:
  5163                      - 8646879
  5164                      - 24350896
  5165                      - 36438778
  5166                      - 30657443
  5167                    usage_in_usermode: 50000000
  5168                    total_usage: 100093996
  5169                    usage_in_kernelmode: 30000000
  5170                  system_cpu_usage: 9492140000000
  5171                  online_cpus: 4
  5172                  throttling_data:
  5173                    periods: 0
  5174                    throttled_periods: 0
  5175                    throttled_time: 0
  5176          404:
  5177            description: "no such container"
  5178            schema:
  5179              $ref: "#/definitions/ErrorResponse"
  5180            examples:
  5181              application/json:
  5182                message: "No such container: c2ada9df5af8"
  5183          500:
  5184            description: "server error"
  5185            schema:
  5186              $ref: "#/definitions/ErrorResponse"
  5187        parameters:
  5188          - name: "id"
  5189            in: "path"
  5190            required: true
  5191            description: "ID or name of the container"
  5192            type: "string"
  5193          - name: "stream"
  5194            in: "query"
  5195            description: "Stream the output. If false, the stats will be output once and then it will disconnect."
  5196            type: "boolean"
  5197            default: true
  5198        tags: ["Container"]
  5199    /containers/{id}/resize:
  5200      post:
  5201        summary: "Resize a container TTY"
  5202        description: "Resize the TTY for a container. You must restart the container for the resize to take effect."
  5203        operationId: "ContainerResize"
  5204        consumes:
  5205          - "application/octet-stream"
  5206        produces:
  5207          - "text/plain"
  5208        responses:
  5209          200:
  5210            description: "no error"
  5211          404:
  5212            description: "no such container"
  5213            schema:
  5214              $ref: "#/definitions/ErrorResponse"
  5215            examples:
  5216              application/json:
  5217                message: "No such container: c2ada9df5af8"
  5218          500:
  5219            description: "cannot resize container"
  5220            schema:
  5221              $ref: "#/definitions/ErrorResponse"
  5222        parameters:
  5223          - name: "id"
  5224            in: "path"
  5225            required: true
  5226            description: "ID or name of the container"
  5227            type: "string"
  5228          - name: "h"
  5229            in: "query"
  5230            description: "Height of the tty session in characters"
  5231            type: "integer"
  5232          - name: "w"
  5233            in: "query"
  5234            description: "Width of the tty session in characters"
  5235            type: "integer"
  5236        tags: ["Container"]
  5237    /containers/{id}/start:
  5238      post:
  5239        summary: "Start a container"
  5240        operationId: "ContainerStart"
  5241        responses:
  5242          204:
  5243            description: "no error"
  5244          304:
  5245            description: "container already started"
  5246            schema:
  5247              $ref: "#/definitions/ErrorResponse"
  5248          404:
  5249            description: "no such container"
  5250            schema:
  5251              $ref: "#/definitions/ErrorResponse"
  5252            examples:
  5253              application/json:
  5254                message: "No such container: c2ada9df5af8"
  5255          500:
  5256            description: "server error"
  5257            schema:
  5258              $ref: "#/definitions/ErrorResponse"
  5259        parameters:
  5260          - name: "id"
  5261            in: "path"
  5262            required: true
  5263            description: "ID or name of the container"
  5264            type: "string"
  5265          - name: "detachKeys"
  5266            in: "query"
  5267            description: "Override the key sequence for detaching a container. Format is a single character `[a-Z]` or `ctrl-<value>` where `<value>` is one of: `a-z`, `@`, `^`, `[`, `,` or `_`."
  5268            type: "string"
  5269        tags: ["Container"]
  5270    /containers/{id}/stop:
  5271      post:
  5272        summary: "Stop a container"
  5273        operationId: "ContainerStop"
  5274        responses:
  5275          204:
  5276            description: "no error"
  5277          304:
  5278            description: "container already stopped"
  5279            schema:
  5280              $ref: "#/definitions/ErrorResponse"
  5281          404:
  5282            description: "no such container"
  5283            schema:
  5284              $ref: "#/definitions/ErrorResponse"
  5285            examples:
  5286              application/json:
  5287                message: "No such container: c2ada9df5af8"
  5288          500:
  5289            description: "server error"
  5290            schema:
  5291              $ref: "#/definitions/ErrorResponse"
  5292        parameters:
  5293          - name: "id"
  5294            in: "path"
  5295            required: true
  5296            description: "ID or name of the container"
  5297            type: "string"
  5298          - name: "t"
  5299            in: "query"
  5300            description: "Number of seconds to wait before killing the container"
  5301            type: "integer"
  5302        tags: ["Container"]
  5303    /containers/{id}/restart:
  5304      post:
  5305        summary: "Restart a container"
  5306        operationId: "ContainerRestart"
  5307        responses:
  5308          204:
  5309            description: "no error"
  5310          404:
  5311            description: "no such container"
  5312            schema:
  5313              $ref: "#/definitions/ErrorResponse"
  5314            examples:
  5315              application/json:
  5316                message: "No such container: c2ada9df5af8"
  5317          500:
  5318            description: "server error"
  5319            schema:
  5320              $ref: "#/definitions/ErrorResponse"
  5321        parameters:
  5322          - name: "id"
  5323            in: "path"
  5324            required: true
  5325            description: "ID or name of the container"
  5326            type: "string"
  5327          - name: "t"
  5328            in: "query"
  5329            description: "Number of seconds to wait before killing the container"
  5330            type: "integer"
  5331        tags: ["Container"]
  5332    /containers/{id}/kill:
  5333      post:
  5334        summary: "Kill a container"
  5335        description: "Send a POSIX signal to a container, defaulting to killing to the container."
  5336        operationId: "ContainerKill"
  5337        responses:
  5338          204:
  5339            description: "no error"
  5340          404:
  5341            description: "no such container"
  5342            schema:
  5343              $ref: "#/definitions/ErrorResponse"
  5344            examples:
  5345              application/json:
  5346                message: "No such container: c2ada9df5af8"
  5347          500:
  5348            description: "server error"
  5349            schema:
  5350              $ref: "#/definitions/ErrorResponse"
  5351        parameters:
  5352          - name: "id"
  5353            in: "path"
  5354            required: true
  5355            description: "ID or name of the container"
  5356            type: "string"
  5357          - name: "signal"
  5358            in: "query"
  5359            description: "Signal to send to the container as an integer or string (e.g. `SIGINT`)"
  5360            type: "string"
  5361            default: "SIGKILL"
  5362        tags: ["Container"]
  5363    /containers/{id}/update:
  5364      post:
  5365        summary: "Update a container"
  5366        description: "Change various configuration options of a container without having to recreate it."
  5367        operationId: "ContainerUpdate"
  5368        consumes: ["application/json"]
  5369        produces: ["application/json"]
  5370        responses:
  5371          200:
  5372            description: "The container has been updated."
  5373            schema:
  5374              type: "object"
  5375              properties:
  5376                Warnings:
  5377                  type: "array"
  5378                  items:
  5379                    type: "string"
  5380          404:
  5381            description: "no such container"
  5382            schema:
  5383              $ref: "#/definitions/ErrorResponse"
  5384            examples:
  5385              application/json:
  5386                message: "No such container: c2ada9df5af8"
  5387          500:
  5388            description: "server error"
  5389            schema:
  5390              $ref: "#/definitions/ErrorResponse"
  5391        parameters:
  5392          - name: "id"
  5393            in: "path"
  5394            required: true
  5395            description: "ID or name of the container"
  5396            type: "string"
  5397          - name: "update"
  5398            in: "body"
  5399            required: true
  5400            schema:
  5401              allOf:
  5402                - $ref: "#/definitions/Resources"
  5403                - type: "object"
  5404                  properties:
  5405                    RestartPolicy:
  5406                      $ref: "#/definitions/RestartPolicy"
  5407              example:
  5408                BlkioWeight: 300
  5409                CpuShares: 512
  5410                CpuPeriod: 100000
  5411                CpuQuota: 50000
  5412                CpuRealtimePeriod: 1000000
  5413                CpuRealtimeRuntime: 10000
  5414                CpusetCpus: "0,1"
  5415                CpusetMems: "0"
  5416                Memory: 314572800
  5417                MemorySwap: 514288000
  5418                MemoryReservation: 209715200
  5419                KernelMemory: 52428800
  5420                RestartPolicy:
  5421                  MaximumRetryCount: 4
  5422                  Name: "on-failure"
  5423        tags: ["Container"]
  5424    /containers/{id}/rename:
  5425      post:
  5426        summary: "Rename a container"
  5427        operationId: "ContainerRename"
  5428        responses:
  5429          204:
  5430            description: "no error"
  5431          404:
  5432            description: "no such container"
  5433            schema:
  5434              $ref: "#/definitions/ErrorResponse"
  5435            examples:
  5436              application/json:
  5437                message: "No such container: c2ada9df5af8"
  5438          409:
  5439            description: "name already in use"
  5440            schema:
  5441              $ref: "#/definitions/ErrorResponse"
  5442          500:
  5443            description: "server error"
  5444            schema:
  5445              $ref: "#/definitions/ErrorResponse"
  5446        parameters:
  5447          - name: "id"
  5448            in: "path"
  5449            required: true
  5450            description: "ID or name of the container"
  5451            type: "string"
  5452          - name: "name"
  5453            in: "query"
  5454            required: true
  5455            description: "New name for the container"
  5456            type: "string"
  5457        tags: ["Container"]
  5458    /containers/{id}/pause:
  5459      post:
  5460        summary: "Pause a container"
  5461        description: |
  5462          Use the cgroups freezer to suspend all processes in a container.
  5463  
  5464          Traditionally, when suspending a process the `SIGSTOP` signal is used, which is observable by the process being suspended. With the cgroups freezer the process is unaware, and unable to capture, that it is being suspended, and subsequently resumed.
  5465        operationId: "ContainerPause"
  5466        responses:
  5467          204:
  5468            description: "no error"
  5469          404:
  5470            description: "no such container"
  5471            schema:
  5472              $ref: "#/definitions/ErrorResponse"
  5473            examples:
  5474              application/json:
  5475                message: "No such container: c2ada9df5af8"
  5476          500:
  5477            description: "server error"
  5478            schema:
  5479              $ref: "#/definitions/ErrorResponse"
  5480        parameters:
  5481          - name: "id"
  5482            in: "path"
  5483            required: true
  5484            description: "ID or name of the container"
  5485            type: "string"
  5486        tags: ["Container"]
  5487    /containers/{id}/unpause:
  5488      post:
  5489        summary: "Unpause a container"
  5490        description: "Resume a container which has been paused."
  5491        operationId: "ContainerUnpause"
  5492        responses:
  5493          204:
  5494            description: "no error"
  5495          404:
  5496            description: "no such container"
  5497            schema:
  5498              $ref: "#/definitions/ErrorResponse"
  5499            examples:
  5500              application/json:
  5501                message: "No such container: c2ada9df5af8"
  5502          500:
  5503            description: "server error"
  5504            schema:
  5505              $ref: "#/definitions/ErrorResponse"
  5506        parameters:
  5507          - name: "id"
  5508            in: "path"
  5509            required: true
  5510            description: "ID or name of the container"
  5511            type: "string"
  5512        tags: ["Container"]
  5513    /containers/{id}/attach:
  5514      post:
  5515        summary: "Attach to a container"
  5516        description: |
  5517          Attach to a container to read its output or send it input. You can attach to the same container multiple times and you can reattach to containers that have been detached.
  5518  
  5519          Either the `stream` or `logs` parameter must be `true` for this endpoint to do anything.
  5520  
  5521          See [the documentation for the `docker attach` command](https://docs.docker.com/engine/reference/commandline/attach/) for more details.
  5522  
  5523          ### Hijacking
  5524  
  5525          This endpoint hijacks the HTTP connection to transport `stdin`, `stdout`, and `stderr` on the same socket.
  5526  
  5527          This is the response from the daemon for an attach request:
  5528  
  5529          ```
  5530          HTTP/1.1 200 OK
  5531          Content-Type: application/vnd.docker.raw-stream
  5532  
  5533          [STREAM]
  5534          ```
  5535  
  5536          After the headers and two new lines, the TCP connection can now be used for raw, bidirectional communication between the client and server.
  5537  
  5538          To hint potential proxies about connection hijacking, the Docker client can also optionally send connection upgrade headers.
  5539  
  5540          For example, the client sends this request to upgrade the connection:
  5541  
  5542          ```
  5543          POST /containers/16253994b7c4/attach?stream=1&stdout=1 HTTP/1.1
  5544          Upgrade: tcp
  5545          Connection: Upgrade
  5546          ```
  5547  
  5548          The Docker daemon will respond with a `101 UPGRADED` response, and will similarly follow with the raw stream:
  5549  
  5550          ```
  5551          HTTP/1.1 101 UPGRADED
  5552          Content-Type: application/vnd.docker.raw-stream
  5553          Connection: Upgrade
  5554          Upgrade: tcp
  5555  
  5556          [STREAM]
  5557          ```
  5558  
  5559          ### Stream format
  5560  
  5561          When the TTY setting is disabled in [`POST /containers/create`](#operation/ContainerCreate), the stream over the hijacked connected is multiplexed to separate out `stdout` and `stderr`. The stream consists of a series of frames, each containing a header and a payload.
  5562  
  5563          The header contains the information which the stream writes (`stdout` or `stderr`). It also contains the size of the associated frame encoded in the last four bytes (`uint32`).
  5564  
  5565          It is encoded on the first eight bytes like this:
  5566  
  5567          ```go
  5568          header := [8]byte{STREAM_TYPE, 0, 0, 0, SIZE1, SIZE2, SIZE3, SIZE4}
  5569          ```
  5570  
  5571          `STREAM_TYPE` can be:
  5572  
  5573          - 0: `stdin` (is written on `stdout`)
  5574          - 1: `stdout`
  5575          - 2: `stderr`
  5576  
  5577          `SIZE1, SIZE2, SIZE3, SIZE4` are the four bytes of the `uint32` size encoded as big endian.
  5578  
  5579          Following the header is the payload, which is the specified number of bytes of `STREAM_TYPE`.
  5580  
  5581          The simplest way to implement this protocol is the following:
  5582  
  5583          1. Read 8 bytes.
  5584          2. Choose `stdout` or `stderr` depending on the first byte.
  5585          3. Extract the frame size from the last four bytes.
  5586          4. Read the extracted size and output it on the correct output.
  5587          5. Goto 1.
  5588  
  5589          ### Stream format when using a TTY
  5590  
  5591          When the TTY setting is enabled in [`POST /containers/create`](#operation/ContainerCreate), the stream is not multiplexed. The data exchanged over the hijacked connection is simply the raw data from the process PTY and client's `stdin`.
  5592  
  5593        operationId: "ContainerAttach"
  5594        produces:
  5595          - "application/vnd.docker.raw-stream"
  5596        responses:
  5597          101:
  5598            description: "no error, hints proxy about hijacking"
  5599          200:
  5600            description: "no error, no upgrade header found"
  5601          400:
  5602            description: "bad parameter"
  5603            schema:
  5604              $ref: "#/definitions/ErrorResponse"
  5605          404:
  5606            description: "no such container"
  5607            schema:
  5608              $ref: "#/definitions/ErrorResponse"
  5609            examples:
  5610              application/json:
  5611                message: "No such container: c2ada9df5af8"
  5612          500:
  5613            description: "server error"
  5614            schema:
  5615              $ref: "#/definitions/ErrorResponse"
  5616        parameters:
  5617          - name: "id"
  5618            in: "path"
  5619            required: true
  5620            description: "ID or name of the container"
  5621            type: "string"
  5622          - name: "detachKeys"
  5623            in: "query"
  5624            description: "Override the key sequence for detaching a container.Format is a single character `[a-Z]` or `ctrl-<value>` where `<value>` is one of: `a-z`, `@`, `^`, `[`, `,` or `_`."
  5625            type: "string"
  5626          - name: "logs"
  5627            in: "query"
  5628            description: |
  5629              Replay previous logs from the container.
  5630  
  5631              This is useful for attaching to a container that has started and you want to output everything since the container started.
  5632  
  5633              If `stream` is also enabled, once all the previous output has been returned, it will seamlessly transition into streaming current output.
  5634            type: "boolean"
  5635            default: false
  5636          - name: "stream"
  5637            in: "query"
  5638            description: "Stream attached streams from the time the request was made onwards"
  5639            type: "boolean"
  5640            default: false
  5641          - name: "stdin"
  5642            in: "query"
  5643            description: "Attach to `stdin`"
  5644            type: "boolean"
  5645            default: false
  5646          - name: "stdout"
  5647            in: "query"
  5648            description: "Attach to `stdout`"
  5649            type: "boolean"
  5650            default: false
  5651          - name: "stderr"
  5652            in: "query"
  5653            description: "Attach to `stderr`"
  5654            type: "boolean"
  5655            default: false
  5656        tags: ["Container"]
  5657    /containers/{id}/attach/ws:
  5658      get:
  5659        summary: "Attach to a container via a websocket"
  5660        operationId: "ContainerAttachWebsocket"
  5661        responses:
  5662          101:
  5663            description: "no error, hints proxy about hijacking"
  5664          200:
  5665            description: "no error, no upgrade header found"
  5666          400:
  5667            description: "bad parameter"
  5668            schema:
  5669              $ref: "#/definitions/ErrorResponse"
  5670          404:
  5671            description: "no such container"
  5672            schema:
  5673              $ref: "#/definitions/ErrorResponse"
  5674            examples:
  5675              application/json:
  5676                message: "No such container: c2ada9df5af8"
  5677          500:
  5678            description: "server error"
  5679            schema:
  5680              $ref: "#/definitions/ErrorResponse"
  5681        parameters:
  5682          - name: "id"
  5683            in: "path"
  5684            required: true
  5685            description: "ID or name of the container"
  5686            type: "string"
  5687          - name: "detachKeys"
  5688            in: "query"
  5689            description: "Override the key sequence for detaching a container.Format is a single character `[a-Z]` or `ctrl-<value>` where `<value>` is one of: `a-z`, `@`, `^`, `[`, `,`, or `_`."
  5690            type: "string"
  5691          - name: "logs"
  5692            in: "query"
  5693            description: "Return logs"
  5694            type: "boolean"
  5695            default: false
  5696          - name: "stream"
  5697            in: "query"
  5698            description: "Return stream"
  5699            type: "boolean"
  5700            default: false
  5701          - name: "stdin"
  5702            in: "query"
  5703            description: "Attach to `stdin`"
  5704            type: "boolean"
  5705            default: false
  5706          - name: "stdout"
  5707            in: "query"
  5708            description: "Attach to `stdout`"
  5709            type: "boolean"
  5710            default: false
  5711          - name: "stderr"
  5712            in: "query"
  5713            description: "Attach to `stderr`"
  5714            type: "boolean"
  5715            default: false
  5716        tags: ["Container"]
  5717    /containers/{id}/wait:
  5718      post:
  5719        summary: "Wait for a container"
  5720        description: "Block until a container stops, then returns the exit code."
  5721        operationId: "ContainerWait"
  5722        produces: ["application/json"]
  5723        responses:
  5724          200:
  5725            description: "The container has exit."
  5726            schema:
  5727              type: "object"
  5728              required: [StatusCode]
  5729              properties:
  5730                StatusCode:
  5731                  description: "Exit code of the container"
  5732                  type: "integer"
  5733                  x-nullable: false
  5734                Error:
  5735                  description: "container waiting error, if any"
  5736                  type: "object"
  5737                  properties:
  5738                    Message:
  5739                      description: "Details of an error"
  5740                      type: "string"
  5741          404:
  5742            description: "no such container"
  5743            schema:
  5744              $ref: "#/definitions/ErrorResponse"
  5745            examples:
  5746              application/json:
  5747                message: "No such container: c2ada9df5af8"
  5748          500:
  5749            description: "server error"
  5750            schema:
  5751              $ref: "#/definitions/ErrorResponse"
  5752        parameters:
  5753          - name: "id"
  5754            in: "path"
  5755            required: true
  5756            description: "ID or name of the container"
  5757            type: "string"
  5758          - name: "condition"
  5759            in: "query"
  5760            description: "Wait until a container state reaches the given condition, either 'not-running' (default), 'next-exit', or 'removed'."
  5761            type: "string"
  5762            default: "not-running"
  5763        tags: ["Container"]
  5764    /containers/{id}:
  5765      delete:
  5766        summary: "Remove a container"
  5767        operationId: "ContainerDelete"
  5768        responses:
  5769          204:
  5770            description: "no error"
  5771          400:
  5772            description: "bad parameter"
  5773            schema:
  5774              $ref: "#/definitions/ErrorResponse"
  5775          404:
  5776            description: "no such container"
  5777            schema:
  5778              $ref: "#/definitions/ErrorResponse"
  5779            examples:
  5780              application/json:
  5781                message: "No such container: c2ada9df5af8"
  5782          409:
  5783            description: "conflict"
  5784            schema:
  5785              $ref: "#/definitions/ErrorResponse"
  5786            examples:
  5787              application/json:
  5788                message: "You cannot remove a running container: c2ada9df5af8. Stop the container before attempting removal or force remove"
  5789          500:
  5790            description: "server error"
  5791            schema:
  5792              $ref: "#/definitions/ErrorResponse"
  5793        parameters:
  5794          - name: "id"
  5795            in: "path"
  5796            required: true
  5797            description: "ID or name of the container"
  5798            type: "string"
  5799          - name: "v"
  5800            in: "query"
  5801            description: "Remove the volumes associated with the container."
  5802            type: "boolean"
  5803            default: false
  5804          - name: "force"
  5805            in: "query"
  5806            description: "If the container is running, kill it before removing it."
  5807            type: "boolean"
  5808            default: false
  5809          - name: "link"
  5810            in: "query"
  5811            description: "Remove the specified link associated with the container."
  5812            type: "boolean"
  5813            default: false
  5814        tags: ["Container"]
  5815    /containers/{id}/archive:
  5816      head:
  5817        summary: "Get information about files in a container"
  5818        description: "A response header `X-Docker-Container-Path-Stat` is return containing a base64 - encoded JSON object with some filesystem header information about the path."
  5819        operationId: "ContainerArchiveInfo"
  5820        responses:
  5821          200:
  5822            description: "no error"
  5823            headers:
  5824              X-Docker-Container-Path-Stat:
  5825                type: "string"
  5826                description: "TODO"
  5827          400:
  5828            description: "Bad parameter"
  5829            schema:
  5830              allOf:
  5831                - $ref: "#/definitions/ErrorResponse"
  5832                - type: "object"
  5833                  properties:
  5834                    message:
  5835                      description: "The error message. Either \"must specify path parameter\" (path cannot be empty) or \"not a directory\" (path was asserted to be a directory but exists as a file)."
  5836                      type: "string"
  5837                      x-nullable: false
  5838          404:
  5839            description: "Container or path does not exist"
  5840            schema:
  5841              $ref: "#/definitions/ErrorResponse"
  5842            examples:
  5843              application/json:
  5844                message: "No such container: c2ada9df5af8"
  5845          500:
  5846            description: "Server error"
  5847            schema:
  5848              $ref: "#/definitions/ErrorResponse"
  5849        parameters:
  5850          - name: "id"
  5851            in: "path"
  5852            required: true
  5853            description: "ID or name of the container"
  5854            type: "string"
  5855          - name: "path"
  5856            in: "query"
  5857            required: true
  5858            description: "Resource in the container’s filesystem to archive."
  5859            type: "string"
  5860        tags: ["Container"]
  5861      get:
  5862        summary: "Get an archive of a filesystem resource in a container"
  5863        description: "Get a tar archive of a resource in the filesystem of container id."
  5864        operationId: "ContainerArchive"
  5865        produces: ["application/x-tar"]
  5866        responses:
  5867          200:
  5868            description: "no error"
  5869          400:
  5870            description: "Bad parameter"
  5871            schema:
  5872              allOf:
  5873                - $ref: "#/definitions/ErrorResponse"
  5874                - type: "object"
  5875                  properties:
  5876                    message:
  5877                      description: "The error message. Either \"must specify path parameter\" (path cannot be empty) or \"not a directory\" (path was asserted to be a directory but exists as a file)."
  5878                      type: "string"
  5879                      x-nullable: false
  5880          404:
  5881            description: "Container or path does not exist"
  5882            schema:
  5883              $ref: "#/definitions/ErrorResponse"
  5884            examples:
  5885              application/json:
  5886                message: "No such container: c2ada9df5af8"
  5887          500:
  5888            description: "server error"
  5889            schema:
  5890              $ref: "#/definitions/ErrorResponse"
  5891        parameters:
  5892          - name: "id"
  5893            in: "path"
  5894            required: true
  5895            description: "ID or name of the container"
  5896            type: "string"
  5897          - name: "path"
  5898            in: "query"
  5899            required: true
  5900            description: "Resource in the container’s filesystem to archive."
  5901            type: "string"
  5902        tags: ["Container"]
  5903      put:
  5904        summary: "Extract an archive of files or folders to a directory in a container"
  5905        description: "Upload a tar archive to be extracted to a path in the filesystem of container id."
  5906        operationId: "PutContainerArchive"
  5907        consumes: ["application/x-tar", "application/octet-stream"]
  5908        responses:
  5909          200:
  5910            description: "The content was extracted successfully"
  5911          400:
  5912            description: "Bad parameter"
  5913            schema:
  5914              $ref: "#/definitions/ErrorResponse"
  5915          403:
  5916            description: "Permission denied, the volume or container rootfs is marked as read-only."
  5917            schema:
  5918              $ref: "#/definitions/ErrorResponse"
  5919          404:
  5920            description: "No such container or path does not exist inside the container"
  5921            schema:
  5922              $ref: "#/definitions/ErrorResponse"
  5923            examples:
  5924              application/json:
  5925                message: "No such container: c2ada9df5af8"
  5926          500:
  5927            description: "Server error"
  5928            schema:
  5929              $ref: "#/definitions/ErrorResponse"
  5930        parameters:
  5931          - name: "id"
  5932            in: "path"
  5933            required: true
  5934            description: "ID or name of the container"
  5935            type: "string"
  5936          - name: "path"
  5937            in: "query"
  5938            required: true
  5939            description: "Path to a directory in the container to extract the archive’s contents into. "
  5940            type: "string"
  5941          - name: "noOverwriteDirNonDir"
  5942            in: "query"
  5943            description: "If “1”, “true”, or “True” then it will be an error if unpacking the given content would cause an existing directory to be replaced with a non-directory and vice versa."
  5944            type: "string"
  5945          - name: "inputStream"
  5946            in: "body"
  5947            required: true
  5948            description: "The input stream must be a tar archive compressed with one of the following algorithms: identity (no compression), gzip, bzip2, xz."
  5949            schema:
  5950              type: "string"
  5951        tags: ["Container"]
  5952    /containers/prune:
  5953      post:
  5954        summary: "Delete stopped containers"
  5955        produces:
  5956          - "application/json"
  5957        operationId: "ContainerPrune"
  5958        parameters:
  5959          - name: "filters"
  5960            in: "query"
  5961            description: |
  5962              Filters to process on the prune list, encoded as JSON (a `map[string][]string`).
  5963  
  5964              Available filters:
  5965              - `until=<timestamp>` Prune containers created before this timestamp. The `<timestamp>` can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed relative to the daemon machine’s time.
  5966              - `label` (`label=<key>`, `label=<key>=<value>`, `label!=<key>`, or `label!=<key>=<value>`) Prune containers with (or without, in case `label!=...` is used) the specified labels.
  5967            type: "string"
  5968        responses:
  5969          200:
  5970            description: "No error"
  5971            schema:
  5972              type: "object"
  5973              properties:
  5974                ContainersDeleted:
  5975                  description: "Container IDs that were deleted"
  5976                  type: "array"
  5977                  items:
  5978                    type: "string"
  5979                SpaceReclaimed:
  5980                  description: "Disk space reclaimed in bytes"
  5981                  type: "integer"
  5982                  format: "int64"
  5983          500:
  5984            description: "Server error"
  5985            schema:
  5986              $ref: "#/definitions/ErrorResponse"
  5987        tags: ["Container"]
  5988    /images/json:
  5989      get:
  5990        summary: "List Images"
  5991        description: "Returns a list of images on the server. Note that it uses a different, smaller representation of an image than inspecting a single image."
  5992        operationId: "ImageList"
  5993        produces:
  5994          - "application/json"
  5995        responses:
  5996          200:
  5997            description: "Summary image data for the images matching the query"
  5998            schema:
  5999              type: "array"
  6000              items:
  6001                $ref: "#/definitions/ImageSummary"
  6002            examples:
  6003              application/json:
  6004                - Id: "sha256:e216a057b1cb1efc11f8a268f37ef62083e70b1b38323ba252e25ac88904a7e8"
  6005                  ParentId: ""
  6006                  RepoTags:
  6007                    - "ubuntu:12.04"
  6008                    - "ubuntu:precise"
  6009                  RepoDigests:
  6010                    - "ubuntu@sha256:992069aee4016783df6345315302fa59681aae51a8eeb2f889dea59290f21787"
  6011                  Created: 1474925151
  6012                  Size: 103579269
  6013                  VirtualSize: 103579269
  6014                  SharedSize: 0
  6015                  Labels: {}
  6016                  Containers: 2
  6017                - Id: "sha256:3e314f95dcace0f5e4fd37b10862fe8398e3c60ed36600bc0ca5fda78b087175"
  6018                  ParentId: ""
  6019                  RepoTags:
  6020                    - "ubuntu:12.10"
  6021                    - "ubuntu:quantal"
  6022                  RepoDigests:
  6023                    - "ubuntu@sha256:002fba3e3255af10be97ea26e476692a7ebed0bb074a9ab960b2e7a1526b15d7"
  6024                    - "ubuntu@sha256:68ea0200f0b90df725d99d823905b04cf844f6039ef60c60bf3e019915017bd3"
  6025                  Created: 1403128455
  6026                  Size: 172064416
  6027                  VirtualSize: 172064416
  6028                  SharedSize: 0
  6029                  Labels: {}
  6030                  Containers: 5
  6031          500:
  6032            description: "server error"
  6033            schema:
  6034              $ref: "#/definitions/ErrorResponse"
  6035        parameters:
  6036          - name: "all"
  6037            in: "query"
  6038            description: "Show all images. Only images from a final layer (no children) are shown by default."
  6039            type: "boolean"
  6040            default: false
  6041          - name: "filters"
  6042            in: "query"
  6043            description: |
  6044              A JSON encoded value of the filters (a `map[string][]string`) to process on the images list. Available filters:
  6045  
  6046              - `before`=(`<image-name>[:<tag>]`,  `<image id>` or `<image@digest>`)
  6047              - `dangling=true`
  6048              - `label=key` or `label="key=value"` of an image label
  6049              - `reference`=(`<image-name>[:<tag>]`)
  6050              - `since`=(`<image-name>[:<tag>]`,  `<image id>` or `<image@digest>`)
  6051            type: "string"
  6052          - name: "digests"
  6053            in: "query"
  6054            description: "Show digest information as a `RepoDigests` field on each image."
  6055            type: "boolean"
  6056            default: false
  6057        tags: ["Image"]
  6058    /build:
  6059      post:
  6060        summary: "Build an image"
  6061        description: |
  6062          Build an image from a tar archive with a `Dockerfile` in it.
  6063  
  6064          The `Dockerfile` specifies how the image is built from the tar archive. It is typically in the archive's root, but can be at a different path or have a different name by specifying the `dockerfile` parameter. [See the `Dockerfile` reference for more information](https://docs.docker.com/engine/reference/builder/).
  6065  
  6066          The Docker daemon performs a preliminary validation of the `Dockerfile` before starting the build, and returns an error if the syntax is incorrect. After that, each instruction is run one-by-one until the ID of the new image is output.
  6067  
  6068          The build is canceled if the client drops the connection by quitting or being killed.
  6069        operationId: "ImageBuild"
  6070        consumes:
  6071          - "application/octet-stream"
  6072        produces:
  6073          - "application/json"
  6074        parameters:
  6075          - name: "inputStream"
  6076            in: "body"
  6077            description: "A tar archive compressed with one of the following algorithms: identity (no compression), gzip, bzip2, xz."
  6078            schema:
  6079              type: "string"
  6080              format: "binary"
  6081          - name: "dockerfile"
  6082            in: "query"
  6083            description: "Path within the build context to the `Dockerfile`. This is ignored if `remote` is specified and points to an external `Dockerfile`."
  6084            type: "string"
  6085            default: "Dockerfile"
  6086          - name: "t"
  6087            in: "query"
  6088            description: "A name and optional tag to apply to the image in the `name:tag` format. If you omit the tag the default `latest` value is assumed. You can provide several `t` parameters."
  6089            type: "string"
  6090          - name: "extrahosts"
  6091            in: "query"
  6092            description: "Extra hosts to add to /etc/hosts"
  6093            type: "string"
  6094          - name: "remote"
  6095            in: "query"
  6096            description: "A Git repository URI or HTTP/HTTPS context URI. If the URI points to a single text file, the file’s contents are placed into a file called `Dockerfile` and the image is built from that file. If the URI points to a tarball, the file is downloaded by the daemon and the contents therein used as the context for the build. If the URI points to a tarball and the `dockerfile` parameter is also specified, there must be a file with the corresponding path inside the tarball."
  6097            type: "string"
  6098          - name: "q"
  6099            in: "query"
  6100            description: "Suppress verbose build output."
  6101            type: "boolean"
  6102            default: false
  6103          - name: "nocache"
  6104            in: "query"
  6105            description: "Do not use the cache when building the image."
  6106            type: "boolean"
  6107            default: false
  6108          - name: "cachefrom"
  6109            in: "query"
  6110            description: "JSON array of images used for build cache resolution."
  6111            type: "string"
  6112          - name: "pull"
  6113            in: "query"
  6114            description: "Attempt to pull the image even if an older image exists locally."
  6115            type: "string"
  6116          - name: "rm"
  6117            in: "query"
  6118            description: "Remove intermediate containers after a successful build."
  6119            type: "boolean"
  6120            default: true
  6121          - name: "forcerm"
  6122            in: "query"
  6123            description: "Always remove intermediate containers, even upon failure."
  6124            type: "boolean"
  6125            default: false
  6126          - name: "memory"
  6127            in: "query"
  6128            description: "Set memory limit for build."
  6129            type: "integer"
  6130          - name: "memswap"
  6131            in: "query"
  6132            description: "Total memory (memory + swap). Set as `-1` to disable swap."
  6133            type: "integer"
  6134          - name: "cpushares"
  6135            in: "query"
  6136            description: "CPU shares (relative weight)."
  6137            type: "integer"
  6138          - name: "cpusetcpus"
  6139            in: "query"
  6140            description: "CPUs in which to allow execution (e.g., `0-3`, `0,1`)."
  6141            type: "string"
  6142          - name: "cpuperiod"
  6143            in: "query"
  6144            description: "The length of a CPU period in microseconds."
  6145            type: "integer"
  6146          - name: "cpuquota"
  6147            in: "query"
  6148            description: "Microseconds of CPU time that the container can get in a CPU period."
  6149            type: "integer"
  6150          - name: "buildargs"
  6151            in: "query"
  6152            description: "JSON map of string pairs for build-time variables. Users pass these values at build-time. Docker uses the buildargs as the environment context for commands run via the `Dockerfile` RUN instruction, or for variable expansion in other `Dockerfile` instructions. This is not meant for passing secret values. [Read more about the buildargs instruction.](https://docs.docker.com/engine/reference/builder/#arg)"
  6153            type: "integer"
  6154          - name: "shmsize"
  6155            in: "query"
  6156            description: "Size of `/dev/shm` in bytes. The size must be greater than 0. If omitted the system uses 64MB."
  6157            type: "integer"
  6158          - name: "squash"
  6159            in: "query"
  6160            description: "Squash the resulting images layers into a single layer. *(Experimental release only.)*"
  6161            type: "boolean"
  6162          - name: "labels"
  6163            in: "query"
  6164            description: "Arbitrary key/value labels to set on the image, as a JSON map of string pairs."
  6165            type: "string"
  6166          - name: "networkmode"
  6167            in: "query"
  6168            description: "Sets the networking mode for the run commands during
  6169          build. Supported standard values are: `bridge`, `host`, `none`, and
  6170          `container:<name|id>`. Any other value is taken as a custom network's
  6171          name to which this container should connect to."
  6172            type: "string"
  6173          - name: "Content-type"
  6174            in: "header"
  6175            type: "string"
  6176            enum:
  6177              - "application/x-tar"
  6178            default: "application/x-tar"
  6179          - name: "X-Registry-Config"
  6180            in: "header"
  6181            description: |
  6182              This is a base64-encoded JSON object with auth configurations for multiple registries that a build may refer to.
  6183  
  6184              The key is a registry URL, and the value is an auth configuration object, [as described in the authentication section](#section/Authentication). For example:
  6185  
  6186              ```
  6187              {
  6188                "docker.example.com": {
  6189                  "username": "janedoe",
  6190                  "password": "hunter2"
  6191                },
  6192                "https://index.docker.io/v1/": {
  6193                  "username": "mobydock",
  6194                  "password": "conta1n3rize14"
  6195                }
  6196              }
  6197              ```
  6198  
  6199              Only the registry domain name (and port if not the default 443) are required. However, for legacy reasons, the Docker Hub registry must be specified with both a `https://` prefix and a `/v1/` suffix even though Docker will prefer to use the v2 registry API.
  6200            type: "string"
  6201          - name: "platform"
  6202            in: "query"
  6203            description: "Platform in the format os[/arch[/variant]]"
  6204            type: "string"
  6205            default: ""
  6206        responses:
  6207          200:
  6208            description: "no error"
  6209          400:
  6210            description: "Bad parameter"
  6211            schema:
  6212              $ref: "#/definitions/ErrorResponse"
  6213          500:
  6214            description: "server error"
  6215            schema:
  6216              $ref: "#/definitions/ErrorResponse"
  6217        tags: ["Image"]
  6218    /build/prune:
  6219      post:
  6220        summary: "Delete builder cache"
  6221        produces:
  6222          - "application/json"
  6223        operationId: "BuildPrune"
  6224        responses:
  6225          200:
  6226            description: "No error"
  6227            schema:
  6228              type: "object"
  6229              properties:
  6230                SpaceReclaimed:
  6231                  description: "Disk space reclaimed in bytes"
  6232                  type: "integer"
  6233                  format: "int64"
  6234          500:
  6235            description: "Server error"
  6236            schema:
  6237              $ref: "#/definitions/ErrorResponse"
  6238        tags: ["Image"]
  6239    /images/create:
  6240      post:
  6241        summary: "Create an image"
  6242        description: "Create an image by either pulling it from a registry or importing it."
  6243        operationId: "ImageCreate"
  6244        consumes:
  6245          - "text/plain"
  6246          - "application/octet-stream"
  6247        produces:
  6248          - "application/json"
  6249        responses:
  6250          200:
  6251            description: "no error"
  6252          404:
  6253            description: "repository does not exist or no read access"
  6254            schema:
  6255              $ref: "#/definitions/ErrorResponse"
  6256          500:
  6257            description: "server error"
  6258            schema:
  6259              $ref: "#/definitions/ErrorResponse"
  6260        parameters:
  6261          - name: "fromImage"
  6262            in: "query"
  6263            description: "Name of the image to pull. The name may include a tag or digest. This parameter may only be used when pulling an image. The pull is cancelled if the HTTP connection is closed."
  6264            type: "string"
  6265          - name: "fromSrc"
  6266            in: "query"
  6267            description: "Source to import. The value may be a URL from which the image can be retrieved or `-` to read the image from the request body. This parameter may only be used when importing an image."
  6268            type: "string"
  6269          - name: "repo"
  6270            in: "query"
  6271            description: "Repository name given to an image when it is imported. The repo may include a tag. This parameter may only be used when importing an image."
  6272            type: "string"
  6273          - name: "tag"
  6274            in: "query"
  6275            description: "Tag or digest. If empty when pulling an image, this causes all tags for the given image to be pulled."
  6276            type: "string"
  6277          - name: "inputImage"
  6278            in: "body"
  6279            description: "Image content if the value `-` has been specified in fromSrc query parameter"
  6280            schema:
  6281              type: "string"
  6282            required: false
  6283          - name: "X-Registry-Auth"
  6284            in: "header"
  6285            description: "A base64-encoded auth configuration. [See the authentication section for details.](#section/Authentication)"
  6286            type: "string"
  6287          - name: "platform"
  6288            in: "query"
  6289            description: "Platform in the format os[/arch[/variant]]"
  6290            type: "string"
  6291            default: ""
  6292        tags: ["Image"]
  6293    /images/{name}/json:
  6294      get:
  6295        summary: "Inspect an image"
  6296        description: "Return low-level information about an image."
  6297        operationId: "ImageInspect"
  6298        produces:
  6299          - "application/json"
  6300        responses:
  6301          200:
  6302            description: "No error"
  6303            schema:
  6304              $ref: "#/definitions/Image"
  6305            examples:
  6306              application/json:
  6307                Id: "sha256:85f05633ddc1c50679be2b16a0479ab6f7637f8884e0cfe0f4d20e1ebb3d6e7c"
  6308                Container: "cb91e48a60d01f1e27028b4fc6819f4f290b3cf12496c8176ec714d0d390984a"
  6309                Comment: ""
  6310                Os: "linux"
  6311                Architecture: "amd64"
  6312                Parent: "sha256:91e54dfb11794fad694460162bf0cb0a4fa710cfa3f60979c177d920813e267c"
  6313                ContainerConfig:
  6314                  Tty: false
  6315                  Hostname: "e611e15f9c9d"
  6316                  Domainname: ""
  6317                  AttachStdout: false
  6318                  PublishService: ""
  6319                  AttachStdin: false
  6320                  OpenStdin: false
  6321                  StdinOnce: false
  6322                  NetworkDisabled: false
  6323                  OnBuild: []
  6324                  Image: "91e54dfb11794fad694460162bf0cb0a4fa710cfa3f60979c177d920813e267c"
  6325                  User: ""
  6326                  WorkingDir: ""
  6327                  MacAddress: ""
  6328                  AttachStderr: false
  6329                  Labels:
  6330                    com.example.license: "GPL"
  6331                    com.example.version: "1.0"
  6332                    com.example.vendor: "Acme"
  6333                  Env:
  6334                    - "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
  6335                  Cmd:
  6336                    - "/bin/sh"
  6337                    - "-c"
  6338                    - "#(nop) LABEL com.example.vendor=Acme com.example.license=GPL com.example.version=1.0"
  6339                DockerVersion: "1.9.0-dev"
  6340                VirtualSize: 188359297
  6341                Size: 0
  6342                Author: ""
  6343                Created: "2015-09-10T08:30:53.26995814Z"
  6344                GraphDriver:
  6345                  Name: "aufs"
  6346                  Data: {}
  6347                RepoDigests:
  6348                  - "localhost:5000/test/busybox/example@sha256:cbbf2f9a99b47fc460d422812b6a5adff7dfee951d8fa2e4a98caa0382cfbdbf"
  6349                RepoTags:
  6350                  - "example:1.0"
  6351                  - "example:latest"
  6352                  - "example:stable"
  6353                Config:
  6354                  Image: "91e54dfb11794fad694460162bf0cb0a4fa710cfa3f60979c177d920813e267c"
  6355                  NetworkDisabled: false
  6356                  OnBuild: []
  6357                  StdinOnce: false
  6358                  PublishService: ""
  6359                  AttachStdin: false
  6360                  OpenStdin: false
  6361                  Domainname: ""
  6362                  AttachStdout: false
  6363                  Tty: false
  6364                  Hostname: "e611e15f9c9d"
  6365                  Cmd:
  6366                    - "/bin/bash"
  6367                  Env:
  6368                    - "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
  6369                  Labels:
  6370                    com.example.vendor: "Acme"
  6371                    com.example.version: "1.0"
  6372                    com.example.license: "GPL"
  6373                  MacAddress: ""
  6374                  AttachStderr: false
  6375                  WorkingDir: ""
  6376                  User: ""
  6377                RootFS:
  6378                  Type: "layers"
  6379                  Layers:
  6380                    - "sha256:1834950e52ce4d5a88a1bbd131c537f4d0e56d10ff0dd69e66be3b7dfa9df7e6"
  6381                    - "sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef"
  6382          404:
  6383            description: "No such image"
  6384            schema:
  6385              $ref: "#/definitions/ErrorResponse"
  6386            examples:
  6387              application/json:
  6388                message: "No such image: someimage (tag: latest)"
  6389          500:
  6390            description: "Server error"
  6391            schema:
  6392              $ref: "#/definitions/ErrorResponse"
  6393        parameters:
  6394          - name: "name"
  6395            in: "path"
  6396            description: "Image name or id"
  6397            type: "string"
  6398            required: true
  6399        tags: ["Image"]
  6400    /images/{name}/history:
  6401      get:
  6402        summary: "Get the history of an image"
  6403        description: "Return parent layers of an image."
  6404        operationId: "ImageHistory"
  6405        produces: ["application/json"]
  6406        responses:
  6407          200:
  6408            description: "List of image layers"
  6409            schema:
  6410              type: "array"
  6411              items:
  6412                type: "object"
  6413                x-go-name: HistoryResponseItem
  6414                required: [Id, Created, CreatedBy, Tags, Size, Comment]
  6415                properties:
  6416                  Id:
  6417                    type: "string"
  6418                    x-nullable: false
  6419                  Created:
  6420                    type: "integer"
  6421                    format: "int64"
  6422                    x-nullable: false
  6423                  CreatedBy:
  6424                    type: "string"
  6425                    x-nullable: false
  6426                  Tags:
  6427                    type: "array"
  6428                    items:
  6429                      type: "string"
  6430                  Size:
  6431                    type: "integer"
  6432                    format: "int64"
  6433                    x-nullable: false
  6434                  Comment:
  6435                    type: "string"
  6436                    x-nullable: false
  6437            examples:
  6438              application/json:
  6439                - Id: "3db9c44f45209632d6050b35958829c3a2aa256d81b9a7be45b362ff85c54710"
  6440                  Created: 1398108230
  6441                  CreatedBy: "/bin/sh -c #(nop) ADD file:eb15dbd63394e063b805a3c32ca7bf0266ef64676d5a6fab4801f2e81e2a5148 in /"
  6442                  Tags:
  6443                    - "ubuntu:lucid"
  6444                    - "ubuntu:10.04"
  6445                  Size: 182964289
  6446                  Comment: ""
  6447                - Id: "6cfa4d1f33fb861d4d114f43b25abd0ac737509268065cdfd69d544a59c85ab8"
  6448                  Created: 1398108222
  6449                  CreatedBy: "/bin/sh -c #(nop) MAINTAINER Tianon Gravi <admwiggin@gmail.com> - mkimage-debootstrap.sh -i iproute,iputils-ping,ubuntu-minimal -t lucid.tar.xz lucid http://archive.ubuntu.com/ubuntu/"
  6450                  Tags: []
  6451                  Size: 0
  6452                  Comment: ""
  6453                - Id: "511136ea3c5a64f264b78b5433614aec563103b4d4702f3ba7d4d2698e22c158"
  6454                  Created: 1371157430
  6455                  CreatedBy: ""
  6456                  Tags:
  6457                    - "scratch12:latest"
  6458                    - "scratch:latest"
  6459                  Size: 0
  6460                  Comment: "Imported from -"
  6461          404:
  6462            description: "No such image"
  6463            schema:
  6464              $ref: "#/definitions/ErrorResponse"
  6465          500:
  6466            description: "Server error"
  6467            schema:
  6468              $ref: "#/definitions/ErrorResponse"
  6469        parameters:
  6470          - name: "name"
  6471            in: "path"
  6472            description: "Image name or ID"
  6473            type: "string"
  6474            required: true
  6475        tags: ["Image"]
  6476    /images/{name}/push:
  6477      post:
  6478        summary: "Push an image"
  6479        description: |
  6480          Push an image to a registry.
  6481  
  6482          If you wish to push an image on to a private registry, that image must already have a tag which references the registry. For example, `registry.example.com/myimage:latest`.
  6483  
  6484          The push is cancelled if the HTTP connection is closed.
  6485        operationId: "ImagePush"
  6486        consumes:
  6487          - "application/octet-stream"
  6488        responses:
  6489          200:
  6490            description: "No error"
  6491          404:
  6492            description: "No such image"
  6493            schema:
  6494              $ref: "#/definitions/ErrorResponse"
  6495          500:
  6496            description: "Server error"
  6497            schema:
  6498              $ref: "#/definitions/ErrorResponse"
  6499        parameters:
  6500          - name: "name"
  6501            in: "path"
  6502            description: "Image name or ID."
  6503            type: "string"
  6504            required: true
  6505          - name: "tag"
  6506            in: "query"
  6507            description: "The tag to associate with the image on the registry."
  6508            type: "string"
  6509          - name: "X-Registry-Auth"
  6510            in: "header"
  6511            description: "A base64-encoded auth configuration. [See the authentication section for details.](#section/Authentication)"
  6512            type: "string"
  6513            required: true
  6514        tags: ["Image"]
  6515    /images/{name}/tag:
  6516      post:
  6517        summary: "Tag an image"
  6518        description: "Tag an image so that it becomes part of a repository."
  6519        operationId: "ImageTag"
  6520        responses:
  6521          201:
  6522            description: "No error"
  6523          400:
  6524            description: "Bad parameter"
  6525            schema:
  6526              $ref: "#/definitions/ErrorResponse"
  6527          404:
  6528            description: "No such image"
  6529            schema:
  6530              $ref: "#/definitions/ErrorResponse"
  6531          409:
  6532            description: "Conflict"
  6533            schema:
  6534              $ref: "#/definitions/ErrorResponse"
  6535          500:
  6536            description: "Server error"
  6537            schema:
  6538              $ref: "#/definitions/ErrorResponse"
  6539        parameters:
  6540          - name: "name"
  6541            in: "path"
  6542            description: "Image name or ID to tag."
  6543            type: "string"
  6544            required: true
  6545          - name: "repo"
  6546            in: "query"
  6547            description: "The repository to tag in. For example, `someuser/someimage`."
  6548            type: "string"
  6549          - name: "tag"
  6550            in: "query"
  6551            description: "The name of the new tag."
  6552            type: "string"
  6553        tags: ["Image"]
  6554    /images/{name}:
  6555      delete:
  6556        summary: "Remove an image"
  6557        description: |
  6558          Remove an image, along with any untagged parent images that were
  6559          referenced by that image.
  6560  
  6561          Images can't be removed if they have descendant images, are being
  6562          used by a running container or are being used by a build.
  6563        operationId: "ImageDelete"
  6564        produces: ["application/json"]
  6565        responses:
  6566          200:
  6567            description: "The image was deleted successfully"
  6568            schema:
  6569              type: "array"
  6570              items:
  6571                $ref: "#/definitions/ImageDeleteResponseItem"
  6572            examples:
  6573              application/json:
  6574                - Untagged: "3e2f21a89f"
  6575                - Deleted: "3e2f21a89f"
  6576                - Deleted: "53b4f83ac9"
  6577          404:
  6578            description: "No such image"
  6579            schema:
  6580              $ref: "#/definitions/ErrorResponse"
  6581          409:
  6582            description: "Conflict"
  6583            schema:
  6584              $ref: "#/definitions/ErrorResponse"
  6585          500:
  6586            description: "Server error"
  6587            schema:
  6588              $ref: "#/definitions/ErrorResponse"
  6589        parameters:
  6590          - name: "name"
  6591            in: "path"
  6592            description: "Image name or ID"
  6593            type: "string"
  6594            required: true
  6595          - name: "force"
  6596            in: "query"
  6597            description: "Remove the image even if it is being used by stopped containers or has other tags"
  6598            type: "boolean"
  6599            default: false
  6600          - name: "noprune"
  6601            in: "query"
  6602            description: "Do not delete untagged parent images"
  6603            type: "boolean"
  6604            default: false
  6605        tags: ["Image"]
  6606    /images/search:
  6607      get:
  6608        summary: "Search images"
  6609        description: "Search for an image on Docker Hub."
  6610        operationId: "ImageSearch"
  6611        produces:
  6612          - "application/json"
  6613        responses:
  6614          200:
  6615            description: "No error"
  6616            schema:
  6617              type: "array"
  6618              items:
  6619                type: "object"
  6620                properties:
  6621                  description:
  6622                    type: "string"
  6623                  is_official:
  6624                    type: "boolean"
  6625                  is_automated:
  6626                    type: "boolean"
  6627                  name:
  6628                    type: "string"
  6629                  star_count:
  6630                    type: "integer"
  6631            examples:
  6632              application/json:
  6633                - description: ""
  6634                  is_official: false
  6635                  is_automated: false
  6636                  name: "wma55/u1210sshd"
  6637                  star_count: 0
  6638                - description: ""
  6639                  is_official: false
  6640                  is_automated: false
  6641                  name: "jdswinbank/sshd"
  6642                  star_count: 0
  6643                - description: ""
  6644                  is_official: false
  6645                  is_automated: false
  6646                  name: "vgauthier/sshd"
  6647                  star_count: 0
  6648          500:
  6649            description: "Server error"
  6650            schema:
  6651              $ref: "#/definitions/ErrorResponse"
  6652        parameters:
  6653          - name: "term"
  6654            in: "query"
  6655            description: "Term to search"
  6656            type: "string"
  6657            required: true
  6658          - name: "limit"
  6659            in: "query"
  6660            description: "Maximum number of results to return"
  6661            type: "integer"
  6662          - name: "filters"
  6663            in: "query"
  6664            description: |
  6665              A JSON encoded value of the filters (a `map[string][]string`) to process on the images list. Available filters:
  6666  
  6667              - `is-automated=(true|false)`
  6668              - `is-official=(true|false)`
  6669              - `stars=<number>` Matches images that has at least 'number' stars.
  6670            type: "string"
  6671        tags: ["Image"]
  6672    /images/prune:
  6673      post:
  6674        summary: "Delete unused images"
  6675        produces:
  6676          - "application/json"
  6677        operationId: "ImagePrune"
  6678        parameters:
  6679          - name: "filters"
  6680            in: "query"
  6681            description: |
  6682              Filters to process on the prune list, encoded as JSON (a `map[string][]string`). Available filters:
  6683  
  6684              - `dangling=<boolean>` When set to `true` (or `1`), prune only
  6685                 unused *and* untagged images. When set to `false`
  6686                 (or `0`), all unused images are pruned.
  6687              - `until=<string>` Prune images created before this timestamp. The `<timestamp>` can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed relative to the daemon machine’s time.
  6688              - `label` (`label=<key>`, `label=<key>=<value>`, `label!=<key>`, or `label!=<key>=<value>`) Prune images with (or without, in case `label!=...` is used) the specified labels.
  6689            type: "string"
  6690        responses:
  6691          200:
  6692            description: "No error"
  6693            schema:
  6694              type: "object"
  6695              properties:
  6696                ImagesDeleted:
  6697                  description: "Images that were deleted"
  6698                  type: "array"
  6699                  items:
  6700                    $ref: "#/definitions/ImageDeleteResponseItem"
  6701                SpaceReclaimed:
  6702                  description: "Disk space reclaimed in bytes"
  6703                  type: "integer"
  6704                  format: "int64"
  6705          500:
  6706            description: "Server error"
  6707            schema:
  6708              $ref: "#/definitions/ErrorResponse"
  6709        tags: ["Image"]
  6710    /auth:
  6711      post:
  6712        summary: "Check auth configuration"
  6713        description: "Validate credentials for a registry and, if available, get an identity token for accessing the registry without password."
  6714        operationId: "SystemAuth"
  6715        consumes: ["application/json"]
  6716        produces: ["application/json"]
  6717        responses:
  6718          200:
  6719            description: "An identity token was generated successfully."
  6720            schema:
  6721              type: "object"
  6722              required: [Status]
  6723              properties:
  6724                Status:
  6725                  description: "The status of the authentication"
  6726                  type: "string"
  6727                  x-nullable: false
  6728                IdentityToken:
  6729                  description: "An opaque token used to authenticate a user after a successful login"
  6730                  type: "string"
  6731                  x-nullable: false
  6732            examples:
  6733              application/json:
  6734                Status: "Login Succeeded"
  6735                IdentityToken: "9cbaf023786cd7..."
  6736          204:
  6737            description: "No error"
  6738          500:
  6739            description: "Server error"
  6740            schema:
  6741              $ref: "#/definitions/ErrorResponse"
  6742        parameters:
  6743          - name: "authConfig"
  6744            in: "body"
  6745            description: "Authentication to check"
  6746            schema:
  6747              $ref: "#/definitions/AuthConfig"
  6748        tags: ["System"]
  6749    /info:
  6750      get:
  6751        summary: "Get system information"
  6752        operationId: "SystemInfo"
  6753        produces:
  6754          - "application/json"
  6755        responses:
  6756          200:
  6757            description: "No error"
  6758            schema:
  6759              $ref: "#/definitions/SystemInfo"
  6760          500:
  6761            description: "Server error"
  6762            schema:
  6763              $ref: "#/definitions/ErrorResponse"
  6764        tags: ["System"]
  6765    /version:
  6766      get:
  6767        summary: "Get version"
  6768        description: "Returns the version of Docker that is running and various information about the system that Docker is running on."
  6769        operationId: "SystemVersion"
  6770        produces: ["application/json"]
  6771        responses:
  6772          200:
  6773            description: "no error"
  6774            schema:
  6775              type: "object"
  6776              properties:
  6777                Version:
  6778                  type: "string"
  6779                ApiVersion:
  6780                  type: "string"
  6781                MinAPIVersion:
  6782                  type: "string"
  6783                GitCommit:
  6784                  type: "string"
  6785                GoVersion:
  6786                  type: "string"
  6787                Os:
  6788                  type: "string"
  6789                Arch:
  6790                  type: "string"
  6791                KernelVersion:
  6792                  type: "string"
  6793                Experimental:
  6794                  type: "boolean"
  6795                BuildTime:
  6796                  type: "string"
  6797            examples:
  6798              application/json:
  6799                Version: "17.04.0"
  6800                Os: "linux"
  6801                KernelVersion: "3.19.0-23-generic"
  6802                GoVersion: "go1.7.5"
  6803                GitCommit: "deadbee"
  6804                Arch: "amd64"
  6805                ApiVersion: "1.27"
  6806                MinAPIVersion: "1.12"
  6807                BuildTime: "2016-06-14T07:09:13.444803460+00:00"
  6808                Experimental: true
  6809          500:
  6810            description: "server error"
  6811            schema:
  6812              $ref: "#/definitions/ErrorResponse"
  6813        tags: ["System"]
  6814    /_ping:
  6815      get:
  6816        summary: "Ping"
  6817        description: "This is a dummy endpoint you can use to test if the server is accessible."
  6818        operationId: "SystemPing"
  6819        produces: ["text/plain"]
  6820        responses:
  6821          200:
  6822            description: "no error"
  6823            schema:
  6824              type: "string"
  6825              example: "OK"
  6826            headers:
  6827              API-Version:
  6828                type: "string"
  6829                description: "Max API Version the server supports"
  6830              Docker-Experimental:
  6831                type: "boolean"
  6832                description: "If the server is running with experimental mode enabled"
  6833          500:
  6834            description: "server error"
  6835            schema:
  6836              $ref: "#/definitions/ErrorResponse"
  6837        tags: ["System"]
  6838    /commit:
  6839      post:
  6840        summary: "Create a new image from a container"
  6841        operationId: "ImageCommit"
  6842        consumes:
  6843          - "application/json"
  6844        produces:
  6845          - "application/json"
  6846        responses:
  6847          201:
  6848            description: "no error"
  6849            schema:
  6850              $ref: "#/definitions/IdResponse"
  6851          404:
  6852            description: "no such container"
  6853            schema:
  6854              $ref: "#/definitions/ErrorResponse"
  6855            examples:
  6856              application/json:
  6857                message: "No such container: c2ada9df5af8"
  6858          500:
  6859            description: "server error"
  6860            schema:
  6861              $ref: "#/definitions/ErrorResponse"
  6862        parameters:
  6863          - name: "containerConfig"
  6864            in: "body"
  6865            description: "The container configuration"
  6866            schema:
  6867              $ref: "#/definitions/ContainerConfig"
  6868          - name: "container"
  6869            in: "query"
  6870            description: "The ID or name of the container to commit"
  6871            type: "string"
  6872          - name: "repo"
  6873            in: "query"
  6874            description: "Repository name for the created image"
  6875            type: "string"
  6876          - name: "tag"
  6877            in: "query"
  6878            description: "Tag name for the create image"
  6879            type: "string"
  6880          - name: "comment"
  6881            in: "query"
  6882            description: "Commit message"
  6883            type: "string"
  6884          - name: "author"
  6885            in: "query"
  6886            description: "Author of the image (e.g., `John Hannibal Smith <hannibal@a-team.com>`)"
  6887            type: "string"
  6888          - name: "pause"
  6889            in: "query"
  6890            description: "Whether to pause the container before committing"
  6891            type: "boolean"
  6892            default: true
  6893          - name: "changes"
  6894            in: "query"
  6895            description: "`Dockerfile` instructions to apply while committing"
  6896            type: "string"
  6897        tags: ["Image"]
  6898    /events:
  6899      get:
  6900        summary: "Monitor events"
  6901        description: |
  6902          Stream real-time events from the server.
  6903  
  6904          Various objects within Docker report events when something happens to them.
  6905  
  6906          Containers report these events: `attach`, `commit`, `copy`, `create`, `destroy`, `detach`, `die`, `exec_create`, `exec_detach`, `exec_start`, `export`, `health_status`, `kill`, `oom`, `pause`, `rename`, `resize`, `restart`, `start`, `stop`, `top`, `unpause`, and `update`
  6907  
  6908          Images report these events: `delete`, `import`, `load`, `pull`, `push`, `save`, `tag`, and `untag`
  6909  
  6910          Volumes report these events: `create`, `mount`, `unmount`, and `destroy`
  6911  
  6912          Networks report these events: `create`, `connect`, `disconnect`, `destroy`, `update`, and `remove`
  6913  
  6914          The Docker daemon reports these events: `reload`
  6915  
  6916          Services report these events: `create`, `update`, and `remove`
  6917  
  6918          Nodes report these events: `create`, `update`, and `remove`
  6919  
  6920          Secrets report these events: `create`, `update`, and `remove`
  6921  
  6922          Configs report these events: `create`, `update`, and `remove`
  6923  
  6924        operationId: "SystemEvents"
  6925        produces:
  6926          - "application/json"
  6927        responses:
  6928          200:
  6929            description: "no error"
  6930            schema:
  6931              type: "object"
  6932              properties:
  6933                Type:
  6934                  description: "The type of object emitting the event"
  6935                  type: "string"
  6936                Action:
  6937                  description: "The type of event"
  6938                  type: "string"
  6939                Actor:
  6940                  type: "object"
  6941                  properties:
  6942                    ID:
  6943                      description: "The ID of the object emitting the event"
  6944                      type: "string"
  6945                    Attributes:
  6946                      description: "Various key/value attributes of the object, depending on its type"
  6947                      type: "object"
  6948                      additionalProperties:
  6949                        type: "string"
  6950                time:
  6951                  description: "Timestamp of event"
  6952                  type: "integer"
  6953                timeNano:
  6954                  description: "Timestamp of event, with nanosecond accuracy"
  6955                  type: "integer"
  6956                  format: "int64"
  6957            examples:
  6958              application/json:
  6959                Type: "container"
  6960                Action: "create"
  6961                Actor:
  6962                  ID: "ede54ee1afda366ab42f824e8a5ffd195155d853ceaec74a927f249ea270c743"
  6963                  Attributes:
  6964                    com.example.some-label: "some-label-value"
  6965                    image: "alpine"
  6966                    name: "my-container"
  6967                time: 1461943101
  6968          400:
  6969            description: "bad parameter"
  6970            schema:
  6971              $ref: "#/definitions/ErrorResponse"
  6972          500:
  6973            description: "server error"
  6974            schema:
  6975              $ref: "#/definitions/ErrorResponse"
  6976        parameters:
  6977          - name: "since"
  6978            in: "query"
  6979            description: "Show events created since this timestamp then stream new events."
  6980            type: "string"
  6981          - name: "until"
  6982            in: "query"
  6983            description: "Show events created until this timestamp then stop streaming."
  6984            type: "string"
  6985          - name: "filters"
  6986            in: "query"
  6987            description: |
  6988              A JSON encoded value of filters (a `map[string][]string`) to process on the event list. Available filters:
  6989  
  6990              - `config=<string>` config name or ID
  6991              - `container=<string>` container name or ID
  6992              - `daemon=<string>` daemon name or ID
  6993              - `event=<string>` event type
  6994              - `image=<string>` image name or ID
  6995              - `label=<string>` image or container label
  6996              - `network=<string>` network name or ID
  6997              - `node=<string>` node ID
  6998              - `plugin`=<string> plugin name or ID
  6999              - `scope`=<string> local or swarm
  7000              - `secret=<string>` secret name or ID
  7001              - `service=<string>` service name or ID
  7002              - `type=<string>` object to filter by, one of `container`, `image`, `volume`, `network`, `daemon`, `plugin`, `node`, `service`, `secret` or `config`
  7003              - `volume=<string>` volume name
  7004            type: "string"
  7005        tags: ["System"]
  7006    /system/df:
  7007      get:
  7008        summary: "Get data usage information"
  7009        operationId: "SystemDataUsage"
  7010        responses:
  7011          200:
  7012            description: "no error"
  7013            schema:
  7014              type: "object"
  7015              properties:
  7016                LayersSize:
  7017                  type: "integer"
  7018                  format: "int64"
  7019                Images:
  7020                  type: "array"
  7021                  items:
  7022                    $ref: "#/definitions/ImageSummary"
  7023                Containers:
  7024                  type: "array"
  7025                  items:
  7026                    $ref: "#/definitions/ContainerSummary"
  7027                Volumes:
  7028                  type: "array"
  7029                  items:
  7030                    $ref: "#/definitions/Volume"
  7031              example:
  7032                LayersSize: 1092588
  7033                Images:
  7034                  -
  7035                    Id: "sha256:2b8fd9751c4c0f5dd266fcae00707e67a2545ef34f9a29354585f93dac906749"
  7036                    ParentId: ""
  7037                    RepoTags:
  7038                      - "busybox:latest"
  7039                    RepoDigests:
  7040                      - "busybox@sha256:a59906e33509d14c036c8678d687bd4eec81ed7c4b8ce907b888c607f6a1e0e6"
  7041                    Created: 1466724217
  7042                    Size: 1092588
  7043                    SharedSize: 0
  7044                    VirtualSize: 1092588
  7045                    Labels: {}
  7046                    Containers: 1
  7047                Containers:
  7048                  -
  7049                    Id: "e575172ed11dc01bfce087fb27bee502db149e1a0fad7c296ad300bbff178148"
  7050                    Names:
  7051                      - "/top"
  7052                    Image: "busybox"
  7053                    ImageID: "sha256:2b8fd9751c4c0f5dd266fcae00707e67a2545ef34f9a29354585f93dac906749"
  7054                    Command: "top"
  7055                    Created: 1472592424
  7056                    Ports: []
  7057                    SizeRootFs: 1092588
  7058                    Labels: {}
  7059                    State: "exited"
  7060                    Status: "Exited (0) 56 minutes ago"
  7061                    HostConfig:
  7062                      NetworkMode: "default"
  7063                    NetworkSettings:
  7064                      Networks:
  7065                        bridge:
  7066                          IPAMConfig: null
  7067                          Links: null
  7068                          Aliases: null
  7069                          NetworkID: "d687bc59335f0e5c9ee8193e5612e8aee000c8c62ea170cfb99c098f95899d92"
  7070                          EndpointID: "8ed5115aeaad9abb174f68dcf135b49f11daf597678315231a32ca28441dec6a"
  7071                          Gateway: "172.18.0.1"
  7072                          IPAddress: "172.18.0.2"
  7073                          IPPrefixLen: 16
  7074                          IPv6Gateway: ""
  7075                          GlobalIPv6Address: ""
  7076                          GlobalIPv6PrefixLen: 0
  7077                          MacAddress: "02:42:ac:12:00:02"
  7078                    Mounts: []
  7079                Volumes:
  7080                  -
  7081                    Name: "my-volume"
  7082                    Driver: "local"
  7083                    Mountpoint: "/var/lib/docker/volumes/my-volume/_data"
  7084                    Labels: null
  7085                    Scope: "local"
  7086                    Options: null
  7087                    UsageData:
  7088                      Size: 10920104
  7089                      RefCount: 2
  7090          500:
  7091            description: "server error"
  7092            schema:
  7093              $ref: "#/definitions/ErrorResponse"
  7094        tags: ["System"]
  7095    /images/{name}/get:
  7096      get:
  7097        summary: "Export an image"
  7098        description: |
  7099          Get a tarball containing all images and metadata for a repository.
  7100  
  7101          If `name` is a specific name and tag (e.g. `ubuntu:latest`), then only that image (and its parents) are returned. If `name` is an image ID, similarly only that image (and its parents) are returned, but with the exclusion of the `repositories` file in the tarball, as there were no image names referenced.
  7102  
  7103          ### Image tarball format
  7104  
  7105          An image tarball contains one directory per image layer (named using its long ID), each containing these files:
  7106  
  7107          - `VERSION`: currently `1.0` - the file format version
  7108          - `json`: detailed layer information, similar to `docker inspect layer_id`
  7109          - `layer.tar`: A tarfile containing the filesystem changes in this layer
  7110  
  7111          The `layer.tar` file contains `aufs` style `.wh..wh.aufs` files and directories for storing attribute changes and deletions.
  7112  
  7113          If the tarball defines a repository, the tarball should also include a `repositories` file at the root that contains a list of repository and tag names mapped to layer IDs.
  7114  
  7115          ```json
  7116          {
  7117            "hello-world": {
  7118              "latest": "565a9d68a73f6706862bfe8409a7f659776d4d60a8d096eb4a3cbce6999cc2a1"
  7119            }
  7120          }
  7121          ```
  7122        operationId: "ImageGet"
  7123        produces:
  7124          - "application/x-tar"
  7125        responses:
  7126          200:
  7127            description: "no error"
  7128            schema:
  7129              type: "string"
  7130              format: "binary"
  7131          500:
  7132            description: "server error"
  7133            schema:
  7134              $ref: "#/definitions/ErrorResponse"
  7135        parameters:
  7136          - name: "name"
  7137            in: "path"
  7138            description: "Image name or ID"
  7139            type: "string"
  7140            required: true
  7141        tags: ["Image"]
  7142    /images/get:
  7143      get:
  7144        summary: "Export several images"
  7145        description: |
  7146          Get a tarball containing all images and metadata for several image repositories.
  7147  
  7148          For each value of the `names` parameter: if it is a specific name and tag (e.g. `ubuntu:latest`), then only that image (and its parents) are returned; if it is an image ID, similarly only that image (and its parents) are returned and there would be no names referenced in the 'repositories' file for this image ID.
  7149  
  7150          For details on the format, see [the export image endpoint](#operation/ImageGet).
  7151        operationId: "ImageGetAll"
  7152        produces:
  7153          - "application/x-tar"
  7154        responses:
  7155          200:
  7156            description: "no error"
  7157            schema:
  7158              type: "string"
  7159              format: "binary"
  7160          500:
  7161            description: "server error"
  7162            schema:
  7163              $ref: "#/definitions/ErrorResponse"
  7164        parameters:
  7165          - name: "names"
  7166            in: "query"
  7167            description: "Image names to filter by"
  7168            type: "array"
  7169            items:
  7170              type: "string"
  7171        tags: ["Image"]
  7172    /images/load:
  7173      post:
  7174        summary: "Import images"
  7175        description: |
  7176          Load a set of images and tags into a repository.
  7177  
  7178          For details on the format, see [the export image endpoint](#operation/ImageGet).
  7179        operationId: "ImageLoad"
  7180        consumes:
  7181          - "application/x-tar"
  7182        produces:
  7183          - "application/json"
  7184        responses:
  7185          200:
  7186            description: "no error"
  7187          500:
  7188            description: "server error"
  7189            schema:
  7190              $ref: "#/definitions/ErrorResponse"
  7191        parameters:
  7192          - name: "imagesTarball"
  7193            in: "body"
  7194            description: "Tar archive containing images"
  7195            schema:
  7196              type: "string"
  7197              format: "binary"
  7198          - name: "quiet"
  7199            in: "query"
  7200            description: "Suppress progress details during load."
  7201            type: "boolean"
  7202            default: false
  7203        tags: ["Image"]
  7204    /containers/{id}/exec:
  7205      post:
  7206        summary: "Create an exec instance"
  7207        description: "Run a command inside a running container."
  7208        operationId: "ContainerExec"
  7209        consumes:
  7210          - "application/json"
  7211        produces:
  7212          - "application/json"
  7213        responses:
  7214          201:
  7215            description: "no error"
  7216            schema:
  7217              $ref: "#/definitions/IdResponse"
  7218          404:
  7219            description: "no such container"
  7220            schema:
  7221              $ref: "#/definitions/ErrorResponse"
  7222            examples:
  7223              application/json:
  7224                message: "No such container: c2ada9df5af8"
  7225          409:
  7226            description: "container is paused"
  7227            schema:
  7228              $ref: "#/definitions/ErrorResponse"
  7229          500:
  7230            description: "Server error"
  7231            schema:
  7232              $ref: "#/definitions/ErrorResponse"
  7233        parameters:
  7234          - name: "execConfig"
  7235            in: "body"
  7236            description: "Exec configuration"
  7237            schema:
  7238              type: "object"
  7239              properties:
  7240                AttachStdin:
  7241                  type: "boolean"
  7242                  description: "Attach to `stdin` of the exec command."
  7243                AttachStdout:
  7244                  type: "boolean"
  7245                  description: "Attach to `stdout` of the exec command."
  7246                AttachStderr:
  7247                  type: "boolean"
  7248                  description: "Attach to `stderr` of the exec command."
  7249                DetachKeys:
  7250                  type: "string"
  7251                  description: "Override the key sequence for detaching a container. Format is a single character `[a-Z]` or `ctrl-<value>` where `<value>` is one of: `a-z`, `@`, `^`, `[`, `,` or `_`."
  7252                Tty:
  7253                  type: "boolean"
  7254                  description: "Allocate a pseudo-TTY."
  7255                Env:
  7256                  description: "A list of environment variables in the form `[\"VAR=value\", ...]`."
  7257                  type: "array"
  7258                  items:
  7259                    type: "string"
  7260                Cmd:
  7261                  type: "array"
  7262                  description: "Command to run, as a string or array of strings."
  7263                  items:
  7264                    type: "string"
  7265                Privileged:
  7266                  type: "boolean"
  7267                  description: "Runs the exec process with extended privileges."
  7268                  default: false
  7269                User:
  7270                  type: "string"
  7271                  description: "The user, and optionally, group to run the exec process inside the container. Format is one of: `user`, `user:group`, `uid`, or `uid:gid`."
  7272              example:
  7273                AttachStdin: false
  7274                AttachStdout: true
  7275                AttachStderr: true
  7276                DetachKeys: "ctrl-p,ctrl-q"
  7277                Tty: false
  7278                Cmd:
  7279                  - "date"
  7280                Env:
  7281                  - "FOO=bar"
  7282                  - "BAZ=quux"
  7283            required: true
  7284          - name: "id"
  7285            in: "path"
  7286            description: "ID or name of container"
  7287            type: "string"
  7288            required: true
  7289        tags: ["Exec"]
  7290    /exec/{id}/start:
  7291      post:
  7292        summary: "Start an exec instance"
  7293        description: "Starts a previously set up exec instance. If detach is true, this endpoint returns immediately after starting the command. Otherwise, it sets up an interactive session with the command."
  7294        operationId: "ExecStart"
  7295        consumes:
  7296          - "application/json"
  7297        produces:
  7298          - "application/vnd.docker.raw-stream"
  7299        responses:
  7300          200:
  7301            description: "No error"
  7302          404:
  7303            description: "No such exec instance"
  7304            schema:
  7305              $ref: "#/definitions/ErrorResponse"
  7306          409:
  7307            description: "Container is stopped or paused"
  7308            schema:
  7309              $ref: "#/definitions/ErrorResponse"
  7310        parameters:
  7311          - name: "execStartConfig"
  7312            in: "body"
  7313            schema:
  7314              type: "object"
  7315              properties:
  7316                Detach:
  7317                  type: "boolean"
  7318                  description: "Detach from the command."
  7319                Tty:
  7320                  type: "boolean"
  7321                  description: "Allocate a pseudo-TTY."
  7322              example:
  7323                Detach: false
  7324                Tty: false
  7325          - name: "id"
  7326            in: "path"
  7327            description: "Exec instance ID"
  7328            required: true
  7329            type: "string"
  7330        tags: ["Exec"]
  7331    /exec/{id}/resize:
  7332      post:
  7333        summary: "Resize an exec instance"
  7334        description: "Resize the TTY session used by an exec instance. This endpoint only works if `tty` was specified as part of creating and starting the exec instance."
  7335        operationId: "ExecResize"
  7336        responses:
  7337          201:
  7338            description: "No error"
  7339          404:
  7340            description: "No such exec instance"
  7341            schema:
  7342              $ref: "#/definitions/ErrorResponse"
  7343        parameters:
  7344          - name: "id"
  7345            in: "path"
  7346            description: "Exec instance ID"
  7347            required: true
  7348            type: "string"
  7349          - name: "h"
  7350            in: "query"
  7351            description: "Height of the TTY session in characters"
  7352            type: "integer"
  7353          - name: "w"
  7354            in: "query"
  7355            description: "Width of the TTY session in characters"
  7356            type: "integer"
  7357        tags: ["Exec"]
  7358    /exec/{id}/json:
  7359      get:
  7360        summary: "Inspect an exec instance"
  7361        description: "Return low-level information about an exec instance."
  7362        operationId: "ExecInspect"
  7363        produces:
  7364          - "application/json"
  7365        responses:
  7366          200:
  7367            description: "No error"
  7368            schema:
  7369              type: "object"
  7370              properties:
  7371                ID:
  7372                  type: "string"
  7373                Running:
  7374                  type: "boolean"
  7375                ExitCode:
  7376                  type: "integer"
  7377                ProcessConfig:
  7378                  $ref: "#/definitions/ProcessConfig"
  7379                OpenStdin:
  7380                  type: "boolean"
  7381                OpenStderr:
  7382                  type: "boolean"
  7383                OpenStdout:
  7384                  type: "boolean"
  7385                ContainerID:
  7386                  type: "string"
  7387                Pid:
  7388                  type: "integer"
  7389                  description: "The system process ID for the exec process."
  7390            examples:
  7391              application/json:
  7392                CanRemove: false
  7393                ContainerID: "b53ee82b53a40c7dca428523e34f741f3abc51d9f297a14ff874bf761b995126"
  7394                DetachKeys: ""
  7395                ExitCode: 2
  7396                ID: "f33bbfb39f5b142420f4759b2348913bd4a8d1a6d7fd56499cb41a1bb91d7b3b"
  7397                OpenStderr: true
  7398                OpenStdin: true
  7399                OpenStdout: true
  7400                ProcessConfig:
  7401                  arguments:
  7402                    - "-c"
  7403                    - "exit 2"
  7404                  entrypoint: "sh"
  7405                  privileged: false
  7406                  tty: true
  7407                  user: "1000"
  7408                Running: false
  7409                Pid: 42000
  7410          404:
  7411            description: "No such exec instance"
  7412            schema:
  7413              $ref: "#/definitions/ErrorResponse"
  7414          500:
  7415            description: "Server error"
  7416            schema:
  7417              $ref: "#/definitions/ErrorResponse"
  7418        parameters:
  7419          - name: "id"
  7420            in: "path"
  7421            description: "Exec instance ID"
  7422            required: true
  7423            type: "string"
  7424        tags: ["Exec"]
  7425  
  7426    /volumes:
  7427      get:
  7428        summary: "List volumes"
  7429        operationId: "VolumeList"
  7430        produces: ["application/json"]
  7431        responses:
  7432          200:
  7433            description: "Summary volume data that matches the query"
  7434            schema:
  7435              type: "object"
  7436              required: [Volumes, Warnings]
  7437              properties:
  7438                Volumes:
  7439                  type: "array"
  7440                  x-nullable: false
  7441                  description: "List of volumes"
  7442                  items:
  7443                    $ref: "#/definitions/Volume"
  7444                Warnings:
  7445                  type: "array"
  7446                  x-nullable: false
  7447                  description: "Warnings that occurred when fetching the list of volumes"
  7448                  items:
  7449                    type: "string"
  7450  
  7451            examples:
  7452              application/json:
  7453                Volumes:
  7454                  - CreatedAt: "2017-07-19T12:00:26Z"
  7455                    Name: "tardis"
  7456                    Driver: "local"
  7457                    Mountpoint: "/var/lib/docker/volumes/tardis"
  7458                    Labels:
  7459                      com.example.some-label: "some-value"
  7460                      com.example.some-other-label: "some-other-value"
  7461                    Scope: "local"
  7462                    Options:
  7463                      device: "tmpfs"
  7464                      o: "size=100m,uid=1000"
  7465                      type: "tmpfs"
  7466                Warnings: []
  7467          500:
  7468            description: "Server error"
  7469            schema:
  7470              $ref: "#/definitions/ErrorResponse"
  7471        parameters:
  7472          - name: "filters"
  7473            in: "query"
  7474            description: |
  7475              JSON encoded value of the filters (a `map[string][]string`) to
  7476              process on the volumes list. Available filters:
  7477  
  7478              - `dangling=<boolean>` When set to `true` (or `1`), returns all
  7479                 volumes that are not in use by a container. When set to `false`
  7480                 (or `0`), only volumes that are in use by one or more
  7481                 containers are returned.
  7482              - `driver=<volume-driver-name>` Matches volumes based on their driver.
  7483              - `label=<key>` or `label=<key>:<value>` Matches volumes based on
  7484                 the presence of a `label` alone or a `label` and a value.
  7485              - `name=<volume-name>` Matches all or part of a volume name.
  7486            type: "string"
  7487            format: "json"
  7488        tags: ["Volume"]
  7489  
  7490    /volumes/create:
  7491      post:
  7492        summary: "Create a volume"
  7493        operationId: "VolumeCreate"
  7494        consumes: ["application/json"]
  7495        produces: ["application/json"]
  7496        responses:
  7497          201:
  7498            description: "The volume was created successfully"
  7499            schema:
  7500              $ref: "#/definitions/Volume"
  7501          500:
  7502            description: "Server error"
  7503            schema:
  7504              $ref: "#/definitions/ErrorResponse"
  7505        parameters:
  7506          - name: "volumeConfig"
  7507            in: "body"
  7508            required: true
  7509            description: "Volume configuration"
  7510            schema:
  7511              type: "object"
  7512              properties:
  7513                Name:
  7514                  description: "The new volume's name. If not specified, Docker generates a name."
  7515                  type: "string"
  7516                  x-nullable: false
  7517                Driver:
  7518                  description: "Name of the volume driver to use."
  7519                  type: "string"
  7520                  default: "local"
  7521                  x-nullable: false
  7522                DriverOpts:
  7523                  description: "A mapping of driver options and values. These options are passed directly to the driver and are driver specific."
  7524                  type: "object"
  7525                  additionalProperties:
  7526                    type: "string"
  7527                Labels:
  7528                  description: "User-defined key/value metadata."
  7529                  type: "object"
  7530                  additionalProperties:
  7531                    type: "string"
  7532              example:
  7533                Name: "tardis"
  7534                Labels:
  7535                  com.example.some-label: "some-value"
  7536                  com.example.some-other-label: "some-other-value"
  7537                Driver: "custom"
  7538        tags: ["Volume"]
  7539  
  7540    /volumes/{name}:
  7541      get:
  7542        summary: "Inspect a volume"
  7543        operationId: "VolumeInspect"
  7544        produces: ["application/json"]
  7545        responses:
  7546          200:
  7547            description: "No error"
  7548            schema:
  7549              $ref: "#/definitions/Volume"
  7550          404:
  7551            description: "No such volume"
  7552            schema:
  7553              $ref: "#/definitions/ErrorResponse"
  7554          500:
  7555            description: "Server error"
  7556            schema:
  7557              $ref: "#/definitions/ErrorResponse"
  7558        parameters:
  7559          - name: "name"
  7560            in: "path"
  7561            required: true
  7562            description: "Volume name or ID"
  7563            type: "string"
  7564        tags: ["Volume"]
  7565  
  7566      delete:
  7567        summary: "Remove a volume"
  7568        description: "Instruct the driver to remove the volume."
  7569        operationId: "VolumeDelete"
  7570        responses:
  7571          204:
  7572            description: "The volume was removed"
  7573          404:
  7574            description: "No such volume or volume driver"
  7575            schema:
  7576              $ref: "#/definitions/ErrorResponse"
  7577          409:
  7578            description: "Volume is in use and cannot be removed"
  7579            schema:
  7580              $ref: "#/definitions/ErrorResponse"
  7581          500:
  7582            description: "Server error"
  7583            schema:
  7584              $ref: "#/definitions/ErrorResponse"
  7585        parameters:
  7586          - name: "name"
  7587            in: "path"
  7588            required: true
  7589            description: "Volume name or ID"
  7590            type: "string"
  7591          - name: "force"
  7592            in: "query"
  7593            description: "Force the removal of the volume"
  7594            type: "boolean"
  7595            default: false
  7596        tags: ["Volume"]
  7597    /volumes/prune:
  7598      post:
  7599        summary: "Delete unused volumes"
  7600        produces:
  7601          - "application/json"
  7602        operationId: "VolumePrune"
  7603        parameters:
  7604          - name: "filters"
  7605            in: "query"
  7606            description: |
  7607              Filters to process on the prune list, encoded as JSON (a `map[string][]string`).
  7608  
  7609              Available filters:
  7610              - `label` (`label=<key>`, `label=<key>=<value>`, `label!=<key>`, or `label!=<key>=<value>`) Prune volumes with (or without, in case `label!=...` is used) the specified labels.
  7611            type: "string"
  7612        responses:
  7613          200:
  7614            description: "No error"
  7615            schema:
  7616              type: "object"
  7617              properties:
  7618                VolumesDeleted:
  7619                  description: "Volumes that were deleted"
  7620                  type: "array"
  7621                  items:
  7622                    type: "string"
  7623                SpaceReclaimed:
  7624                  description: "Disk space reclaimed in bytes"
  7625                  type: "integer"
  7626                  format: "int64"
  7627          500:
  7628            description: "Server error"
  7629            schema:
  7630              $ref: "#/definitions/ErrorResponse"
  7631        tags: ["Volume"]
  7632    /networks:
  7633      get:
  7634        summary: "List networks"
  7635        description: |
  7636          Returns a list of networks. For details on the format, see [the network inspect endpoint](#operation/NetworkInspect).
  7637  
  7638          Note that it uses a different, smaller representation of a network than inspecting a single network. For example,
  7639          the list of containers attached to the network is not propagated in API versions 1.28 and up.
  7640        operationId: "NetworkList"
  7641        produces:
  7642          - "application/json"
  7643        responses:
  7644          200:
  7645            description: "No error"
  7646            schema:
  7647              type: "array"
  7648              items:
  7649                $ref: "#/definitions/Network"
  7650            examples:
  7651              application/json:
  7652                - Name: "bridge"
  7653                  Id: "f2de39df4171b0dc801e8002d1d999b77256983dfc63041c0f34030aa3977566"
  7654                  Created: "2016-10-19T06:21:00.416543526Z"
  7655                  Scope: "local"
  7656                  Driver: "bridge"
  7657                  EnableIPv6: false
  7658                  Internal: false
  7659                  Attachable: false
  7660                  Ingress: false
  7661                  IPAM:
  7662                    Driver: "default"
  7663                    Config:
  7664                      -
  7665                        Subnet: "172.17.0.0/16"
  7666                  Options:
  7667                    com.docker.network.bridge.default_bridge: "true"
  7668                    com.docker.network.bridge.enable_icc: "true"
  7669                    com.docker.network.bridge.enable_ip_masquerade: "true"
  7670                    com.docker.network.bridge.host_binding_ipv4: "0.0.0.0"
  7671                    com.docker.network.bridge.name: "docker0"
  7672                    com.docker.network.driver.mtu: "1500"
  7673                - Name: "none"
  7674                  Id: "e086a3893b05ab69242d3c44e49483a3bbbd3a26b46baa8f61ab797c1088d794"
  7675                  Created: "0001-01-01T00:00:00Z"
  7676                  Scope: "local"
  7677                  Driver: "null"
  7678                  EnableIPv6: false
  7679                  Internal: false
  7680                  Attachable: false
  7681                  Ingress: false
  7682                  IPAM:
  7683                    Driver: "default"
  7684                    Config: []
  7685                  Containers: {}
  7686                  Options: {}
  7687                - Name: "host"
  7688                  Id: "13e871235c677f196c4e1ecebb9dc733b9b2d2ab589e30c539efeda84a24215e"
  7689                  Created: "0001-01-01T00:00:00Z"
  7690                  Scope: "local"
  7691                  Driver: "host"
  7692                  EnableIPv6: false
  7693                  Internal: false
  7694                  Attachable: false
  7695                  Ingress: false
  7696                  IPAM:
  7697                    Driver: "default"
  7698                    Config: []
  7699                  Containers: {}
  7700                  Options: {}
  7701          500:
  7702            description: "Server error"
  7703            schema:
  7704              $ref: "#/definitions/ErrorResponse"
  7705        parameters:
  7706          - name: "filters"
  7707            in: "query"
  7708            description: |
  7709              JSON encoded value of the filters (a `map[string][]string`) to process on the networks list. Available filters:
  7710  
  7711              - `driver=<driver-name>` Matches a network's driver.
  7712              - `id=<network-id>` Matches all or part of a network ID.
  7713              - `label=<key>` or `label=<key>=<value>` of a network label.
  7714              - `name=<network-name>` Matches all or part of a network name.
  7715              - `scope=["swarm"|"global"|"local"]` Filters networks by scope (`swarm`, `global`, or `local`).
  7716              - `type=["custom"|"builtin"]` Filters networks by type. The `custom` keyword returns all user-defined networks.
  7717            type: "string"
  7718        tags: ["Network"]
  7719  
  7720    /networks/{id}:
  7721      get:
  7722        summary: "Inspect a network"
  7723        operationId: "NetworkInspect"
  7724        produces:
  7725          - "application/json"
  7726        responses:
  7727          200:
  7728            description: "No error"
  7729            schema:
  7730              $ref: "#/definitions/Network"
  7731          404:
  7732            description: "Network not found"
  7733            schema:
  7734              $ref: "#/definitions/ErrorResponse"
  7735          500:
  7736            description: "Server error"
  7737            schema:
  7738              $ref: "#/definitions/ErrorResponse"
  7739        parameters:
  7740          - name: "id"
  7741            in: "path"
  7742            description: "Network ID or name"
  7743            required: true
  7744            type: "string"
  7745          - name: "verbose"
  7746            in: "query"
  7747            description: "Detailed inspect output for troubleshooting"
  7748            type: "boolean"
  7749            default: false
  7750          - name: "scope"
  7751            in: "query"
  7752            description: "Filter the network by scope (swarm, global, or local)"
  7753            type: "string"
  7754        tags: ["Network"]
  7755  
  7756      delete:
  7757        summary: "Remove a network"
  7758        operationId: "NetworkDelete"
  7759        responses:
  7760          204:
  7761            description: "No error"
  7762          403:
  7763            description: "operation not supported for pre-defined networks"
  7764            schema:
  7765              $ref: "#/definitions/ErrorResponse"
  7766          404:
  7767            description: "no such network"
  7768            schema:
  7769              $ref: "#/definitions/ErrorResponse"
  7770          500:
  7771            description: "Server error"
  7772            schema:
  7773              $ref: "#/definitions/ErrorResponse"
  7774        parameters:
  7775          - name: "id"
  7776            in: "path"
  7777            description: "Network ID or name"
  7778            required: true
  7779            type: "string"
  7780        tags: ["Network"]
  7781  
  7782    /networks/create:
  7783      post:
  7784        summary: "Create a network"
  7785        operationId: "NetworkCreate"
  7786        consumes:
  7787          - "application/json"
  7788        produces:
  7789          - "application/json"
  7790        responses:
  7791          201:
  7792            description: "No error"
  7793            schema:
  7794              type: "object"
  7795              properties:
  7796                Id:
  7797                  description: "The ID of the created network."
  7798                  type: "string"
  7799                Warning:
  7800                  type: "string"
  7801              example:
  7802                Id: "22be93d5babb089c5aab8dbc369042fad48ff791584ca2da2100db837a1c7c30"
  7803                Warning: ""
  7804          403:
  7805            description: "operation not supported for pre-defined networks"
  7806            schema:
  7807              $ref: "#/definitions/ErrorResponse"
  7808          404:
  7809            description: "plugin not found"
  7810            schema:
  7811              $ref: "#/definitions/ErrorResponse"
  7812          500:
  7813            description: "Server error"
  7814            schema:
  7815              $ref: "#/definitions/ErrorResponse"
  7816        parameters:
  7817          - name: "networkConfig"
  7818            in: "body"
  7819            description: "Network configuration"
  7820            required: true
  7821            schema:
  7822              type: "object"
  7823              required: ["Name"]
  7824              properties:
  7825                Name:
  7826                  description: "The network's name."
  7827                  type: "string"
  7828                CheckDuplicate:
  7829                  description: "Check for networks with duplicate names. Since Network is primarily keyed based on a random ID and not on the name, and network name is strictly a user-friendly alias to the network which is uniquely identified using ID, there is no guaranteed way to check for duplicates. CheckDuplicate is there to provide a best effort checking of any networks which has the same name but it is not guaranteed to catch all name collisions."
  7830                  type: "boolean"
  7831                Driver:
  7832                  description: "Name of the network driver plugin to use."
  7833                  type: "string"
  7834                  default: "bridge"
  7835                Internal:
  7836                  description: "Restrict external access to the network."
  7837                  type: "boolean"
  7838                Attachable:
  7839                  description: "Globally scoped network is manually attachable by regular containers from workers in swarm mode."
  7840                  type: "boolean"
  7841                Ingress:
  7842                  description: "Ingress network is the network which provides the routing-mesh in swarm mode."
  7843                  type: "boolean"
  7844                IPAM:
  7845                  description: "Optional custom IP scheme for the network."
  7846                  $ref: "#/definitions/IPAM"
  7847                EnableIPv6:
  7848                  description: "Enable IPv6 on the network."
  7849                  type: "boolean"
  7850                Options:
  7851                  description: "Network specific options to be used by the drivers."
  7852                  type: "object"
  7853                  additionalProperties:
  7854                    type: "string"
  7855                Labels:
  7856                  description: "User-defined key/value metadata."
  7857                  type: "object"
  7858                  additionalProperties:
  7859                    type: "string"
  7860              example:
  7861                Name: "isolated_nw"
  7862                CheckDuplicate: false
  7863                Driver: "bridge"
  7864                EnableIPv6: true
  7865                IPAM:
  7866                  Driver: "default"
  7867                  Config:
  7868                    - Subnet: "172.20.0.0/16"
  7869                      IPRange: "172.20.10.0/24"
  7870                      Gateway: "172.20.10.11"
  7871                    - Subnet: "2001:db8:abcd::/64"
  7872                      Gateway: "2001:db8:abcd::1011"
  7873                  Options:
  7874                    foo: "bar"
  7875                Internal: true
  7876                Attachable: false
  7877                Ingress: false
  7878                Options:
  7879                  com.docker.network.bridge.default_bridge: "true"
  7880                  com.docker.network.bridge.enable_icc: "true"
  7881                  com.docker.network.bridge.enable_ip_masquerade: "true"
  7882                  com.docker.network.bridge.host_binding_ipv4: "0.0.0.0"
  7883                  com.docker.network.bridge.name: "docker0"
  7884                  com.docker.network.driver.mtu: "1500"
  7885                Labels:
  7886                  com.example.some-label: "some-value"
  7887                  com.example.some-other-label: "some-other-value"
  7888        tags: ["Network"]
  7889  
  7890    /networks/{id}/connect:
  7891      post:
  7892        summary: "Connect a container to a network"
  7893        operationId: "NetworkConnect"
  7894        consumes:
  7895          - "application/octet-stream"
  7896        responses:
  7897          200:
  7898            description: "No error"
  7899          403:
  7900            description: "Operation not supported for swarm scoped networks"
  7901            schema:
  7902              $ref: "#/definitions/ErrorResponse"
  7903          404:
  7904            description: "Network or container not found"
  7905            schema:
  7906              $ref: "#/definitions/ErrorResponse"
  7907          500:
  7908            description: "Server error"
  7909            schema:
  7910              $ref: "#/definitions/ErrorResponse"
  7911        parameters:
  7912          - name: "id"
  7913            in: "path"
  7914            description: "Network ID or name"
  7915            required: true
  7916            type: "string"
  7917          - name: "container"
  7918            in: "body"
  7919            required: true
  7920            schema:
  7921              type: "object"
  7922              properties:
  7923                Container:
  7924                  type: "string"
  7925                  description: "The ID or name of the container to connect to the network."
  7926                EndpointConfig:
  7927                  $ref: "#/definitions/EndpointSettings"
  7928              example:
  7929                Container: "3613f73ba0e4"
  7930                EndpointConfig:
  7931                  IPAMConfig:
  7932                    IPv4Address: "172.24.56.89"
  7933                    IPv6Address: "2001:db8::5689"
  7934        tags: ["Network"]
  7935  
  7936    /networks/{id}/disconnect:
  7937      post:
  7938        summary: "Disconnect a container from a network"
  7939        operationId: "NetworkDisconnect"
  7940        consumes:
  7941          - "application/json"
  7942        responses:
  7943          200:
  7944            description: "No error"
  7945          403:
  7946            description: "Operation not supported for swarm scoped networks"
  7947            schema:
  7948              $ref: "#/definitions/ErrorResponse"
  7949          404:
  7950            description: "Network or container not found"
  7951            schema:
  7952              $ref: "#/definitions/ErrorResponse"
  7953          500:
  7954            description: "Server error"
  7955            schema:
  7956              $ref: "#/definitions/ErrorResponse"
  7957        parameters:
  7958          - name: "id"
  7959            in: "path"
  7960            description: "Network ID or name"
  7961            required: true
  7962            type: "string"
  7963          - name: "container"
  7964            in: "body"
  7965            required: true
  7966            schema:
  7967              type: "object"
  7968              properties:
  7969                Container:
  7970                  type: "string"
  7971                  description: "The ID or name of the container to disconnect from the network."
  7972                Force:
  7973                  type: "boolean"
  7974                  description: "Force the container to disconnect from the network."
  7975        tags: ["Network"]
  7976    /networks/prune:
  7977      post:
  7978        summary: "Delete unused networks"
  7979        produces:
  7980          - "application/json"
  7981        operationId: "NetworkPrune"
  7982        parameters:
  7983          - name: "filters"
  7984            in: "query"
  7985            description: |
  7986              Filters to process on the prune list, encoded as JSON (a `map[string][]string`).
  7987  
  7988              Available filters:
  7989              - `until=<timestamp>` Prune networks created before this timestamp. The `<timestamp>` can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed relative to the daemon machine’s time.
  7990              - `label` (`label=<key>`, `label=<key>=<value>`, `label!=<key>`, or `label!=<key>=<value>`) Prune networks with (or without, in case `label!=...` is used) the specified labels.
  7991            type: "string"
  7992        responses:
  7993          200:
  7994            description: "No error"
  7995            schema:
  7996              type: "object"
  7997              properties:
  7998                NetworksDeleted:
  7999                  description: "Networks that were deleted"
  8000                  type: "array"
  8001                  items:
  8002                    type: "string"
  8003          500:
  8004            description: "Server error"
  8005            schema:
  8006              $ref: "#/definitions/ErrorResponse"
  8007        tags: ["Network"]
  8008    /plugins:
  8009      get:
  8010        summary: "List plugins"
  8011        operationId: "PluginList"
  8012        description: "Returns information about installed plugins."
  8013        produces: ["application/json"]
  8014        responses:
  8015          200:
  8016            description: "No error"
  8017            schema:
  8018              type: "array"
  8019              items:
  8020                $ref: "#/definitions/Plugin"
  8021          500:
  8022            description: "Server error"
  8023            schema:
  8024              $ref: "#/definitions/ErrorResponse"
  8025        parameters:
  8026          - name: "filters"
  8027            in: "query"
  8028            type: "string"
  8029            description: |
  8030              A JSON encoded value of the filters (a `map[string][]string`) to process on the plugin list. Available filters:
  8031  
  8032              - `capability=<capability name>`
  8033              - `enable=<true>|<false>`
  8034        tags: ["Plugin"]
  8035  
  8036    /plugins/privileges:
  8037      get:
  8038        summary: "Get plugin privileges"
  8039        operationId: "GetPluginPrivileges"
  8040        responses:
  8041          200:
  8042            description: "no error"
  8043            schema:
  8044              type: "array"
  8045              items:
  8046                description: "Describes a permission the user has to accept upon installing the plugin."
  8047                type: "object"
  8048                properties:
  8049                  Name:
  8050                    type: "string"
  8051                  Description:
  8052                    type: "string"
  8053                  Value:
  8054                    type: "array"
  8055                    items:
  8056                      type: "string"
  8057              example:
  8058                - Name: "network"
  8059                  Description: ""
  8060                  Value:
  8061                    - "host"
  8062                - Name: "mount"
  8063                  Description: ""
  8064                  Value:
  8065                    - "/data"
  8066                - Name: "device"
  8067                  Description: ""
  8068                  Value:
  8069                    - "/dev/cpu_dma_latency"
  8070          500:
  8071            description: "server error"
  8072            schema:
  8073              $ref: "#/definitions/ErrorResponse"
  8074        parameters:
  8075          - name: "remote"
  8076            in: "query"
  8077            description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  8078            required: true
  8079            type: "string"
  8080        tags:
  8081          - "Plugin"
  8082  
  8083    /plugins/pull:
  8084      post:
  8085        summary: "Install a plugin"
  8086        operationId: "PluginPull"
  8087        description: |
  8088          Pulls and installs a plugin. After the plugin is installed, it can be enabled using the [`POST /plugins/{name}/enable` endpoint](#operation/PostPluginsEnable).
  8089        produces:
  8090          - "application/json"
  8091        responses:
  8092          204:
  8093            description: "no error"
  8094          500:
  8095            description: "server error"
  8096            schema:
  8097              $ref: "#/definitions/ErrorResponse"
  8098        parameters:
  8099          - name: "remote"
  8100            in: "query"
  8101            description: |
  8102              Remote reference for plugin to install.
  8103  
  8104              The `:latest` tag is optional, and is used as the default if omitted.
  8105            required: true
  8106            type: "string"
  8107          - name: "name"
  8108            in: "query"
  8109            description: |
  8110              Local name for the pulled plugin.
  8111  
  8112              The `:latest` tag is optional, and is used as the default if omitted.
  8113            required: false
  8114            type: "string"
  8115          - name: "X-Registry-Auth"
  8116            in: "header"
  8117            description: "A base64-encoded auth configuration to use when pulling a plugin from a registry. [See the authentication section for details.](#section/Authentication)"
  8118            type: "string"
  8119          - name: "body"
  8120            in: "body"
  8121            schema:
  8122              type: "array"
  8123              items:
  8124                description: "Describes a permission accepted by the user upon installing the plugin."
  8125                type: "object"
  8126                properties:
  8127                  Name:
  8128                    type: "string"
  8129                  Description:
  8130                    type: "string"
  8131                  Value:
  8132                    type: "array"
  8133                    items:
  8134                      type: "string"
  8135              example:
  8136                - Name: "network"
  8137                  Description: ""
  8138                  Value:
  8139                    - "host"
  8140                - Name: "mount"
  8141                  Description: ""
  8142                  Value:
  8143                    - "/data"
  8144                - Name: "device"
  8145                  Description: ""
  8146                  Value:
  8147                    - "/dev/cpu_dma_latency"
  8148        tags: ["Plugin"]
  8149    /plugins/{name}/json:
  8150      get:
  8151        summary: "Inspect a plugin"
  8152        operationId: "PluginInspect"
  8153        responses:
  8154          200:
  8155            description: "no error"
  8156            schema:
  8157              $ref: "#/definitions/Plugin"
  8158          404:
  8159            description: "plugin is not installed"
  8160            schema:
  8161              $ref: "#/definitions/ErrorResponse"
  8162          500:
  8163            description: "server error"
  8164            schema:
  8165              $ref: "#/definitions/ErrorResponse"
  8166        parameters:
  8167          - name: "name"
  8168            in: "path"
  8169            description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  8170            required: true
  8171            type: "string"
  8172        tags: ["Plugin"]
  8173    /plugins/{name}:
  8174      delete:
  8175        summary: "Remove a plugin"
  8176        operationId: "PluginDelete"
  8177        responses:
  8178          200:
  8179            description: "no error"
  8180            schema:
  8181              $ref: "#/definitions/Plugin"
  8182          404:
  8183            description: "plugin is not installed"
  8184            schema:
  8185              $ref: "#/definitions/ErrorResponse"
  8186          500:
  8187            description: "server error"
  8188            schema:
  8189              $ref: "#/definitions/ErrorResponse"
  8190        parameters:
  8191          - name: "name"
  8192            in: "path"
  8193            description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  8194            required: true
  8195            type: "string"
  8196          - name: "force"
  8197            in: "query"
  8198            description: "Disable the plugin before removing. This may result in issues if the plugin is in use by a container."
  8199            type: "boolean"
  8200            default: false
  8201        tags: ["Plugin"]
  8202    /plugins/{name}/enable:
  8203      post:
  8204        summary: "Enable a plugin"
  8205        operationId: "PluginEnable"
  8206        responses:
  8207          200:
  8208            description: "no error"
  8209          404:
  8210            description: "plugin is not installed"
  8211            schema:
  8212              $ref: "#/definitions/ErrorResponse"
  8213          500:
  8214            description: "server error"
  8215            schema:
  8216              $ref: "#/definitions/ErrorResponse"
  8217        parameters:
  8218          - name: "name"
  8219            in: "path"
  8220            description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  8221            required: true
  8222            type: "string"
  8223          - name: "timeout"
  8224            in: "query"
  8225            description: "Set the HTTP client timeout (in seconds)"
  8226            type: "integer"
  8227            default: 0
  8228        tags: ["Plugin"]
  8229    /plugins/{name}/disable:
  8230      post:
  8231        summary: "Disable a plugin"
  8232        operationId: "PluginDisable"
  8233        responses:
  8234          200:
  8235            description: "no error"
  8236          404:
  8237            description: "plugin is not installed"
  8238            schema:
  8239              $ref: "#/definitions/ErrorResponse"
  8240          500:
  8241            description: "server error"
  8242            schema:
  8243              $ref: "#/definitions/ErrorResponse"
  8244        parameters:
  8245          - name: "name"
  8246            in: "path"
  8247            description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  8248            required: true
  8249            type: "string"
  8250        tags: ["Plugin"]
  8251    /plugins/{name}/upgrade:
  8252      post:
  8253        summary: "Upgrade a plugin"
  8254        operationId: "PluginUpgrade"
  8255        responses:
  8256          204:
  8257            description: "no error"
  8258          404:
  8259            description: "plugin not installed"
  8260            schema:
  8261              $ref: "#/definitions/ErrorResponse"
  8262          500:
  8263            description: "server error"
  8264            schema:
  8265              $ref: "#/definitions/ErrorResponse"
  8266        parameters:
  8267          - name: "name"
  8268            in: "path"
  8269            description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  8270            required: true
  8271            type: "string"
  8272          - name: "remote"
  8273            in: "query"
  8274            description: |
  8275              Remote reference to upgrade to.
  8276  
  8277              The `:latest` tag is optional, and is used as the default if omitted.
  8278            required: true
  8279            type: "string"
  8280          - name: "X-Registry-Auth"
  8281            in: "header"
  8282            description: "A base64-encoded auth configuration to use when pulling a plugin from a registry. [See the authentication section for details.](#section/Authentication)"
  8283            type: "string"
  8284          - name: "body"
  8285            in: "body"
  8286            schema:
  8287              type: "array"
  8288              items:
  8289                description: "Describes a permission accepted by the user upon installing the plugin."
  8290                type: "object"
  8291                properties:
  8292                  Name:
  8293                    type: "string"
  8294                  Description:
  8295                    type: "string"
  8296                  Value:
  8297                    type: "array"
  8298                    items:
  8299                      type: "string"
  8300              example:
  8301                - Name: "network"
  8302                  Description: ""
  8303                  Value:
  8304                    - "host"
  8305                - Name: "mount"
  8306                  Description: ""
  8307                  Value:
  8308                    - "/data"
  8309                - Name: "device"
  8310                  Description: ""
  8311                  Value:
  8312                    - "/dev/cpu_dma_latency"
  8313        tags: ["Plugin"]
  8314    /plugins/create:
  8315      post:
  8316        summary: "Create a plugin"
  8317        operationId: "PluginCreate"
  8318        consumes:
  8319          - "application/x-tar"
  8320        responses:
  8321          204:
  8322            description: "no error"
  8323          500:
  8324            description: "server error"
  8325            schema:
  8326              $ref: "#/definitions/ErrorResponse"
  8327        parameters:
  8328          - name: "name"
  8329            in: "query"
  8330            description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  8331            required: true
  8332            type: "string"
  8333          - name: "tarContext"
  8334            in: "body"
  8335            description: "Path to tar containing plugin rootfs and manifest"
  8336            schema:
  8337              type: "string"
  8338              format: "binary"
  8339        tags: ["Plugin"]
  8340    /plugins/{name}/push:
  8341      post:
  8342        summary: "Push a plugin"
  8343        operationId: "PluginPush"
  8344        description: |
  8345          Push a plugin to the registry.
  8346        parameters:
  8347          - name: "name"
  8348            in: "path"
  8349            description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  8350            required: true
  8351            type: "string"
  8352        responses:
  8353          200:
  8354            description: "no error"
  8355          404:
  8356            description: "plugin not installed"
  8357            schema:
  8358              $ref: "#/definitions/ErrorResponse"
  8359          500:
  8360            description: "server error"
  8361            schema:
  8362              $ref: "#/definitions/ErrorResponse"
  8363        tags: ["Plugin"]
  8364    /plugins/{name}/set:
  8365      post:
  8366        summary: "Configure a plugin"
  8367        operationId: "PluginSet"
  8368        consumes:
  8369          - "application/json"
  8370        parameters:
  8371          - name: "name"
  8372            in: "path"
  8373            description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  8374            required: true
  8375            type: "string"
  8376          - name: "body"
  8377            in: "body"
  8378            schema:
  8379              type: "array"
  8380              items:
  8381                type: "string"
  8382              example: ["DEBUG=1"]
  8383        responses:
  8384          204:
  8385            description: "No error"
  8386          404:
  8387            description: "Plugin not installed"
  8388            schema:
  8389              $ref: "#/definitions/ErrorResponse"
  8390          500:
  8391            description: "Server error"
  8392            schema:
  8393              $ref: "#/definitions/ErrorResponse"
  8394        tags: ["Plugin"]
  8395    /nodes:
  8396      get:
  8397        summary: "List nodes"
  8398        operationId: "NodeList"
  8399        responses:
  8400          200:
  8401            description: "no error"
  8402            schema:
  8403              type: "array"
  8404              items:
  8405                $ref: "#/definitions/Node"
  8406          500:
  8407            description: "server error"
  8408            schema:
  8409              $ref: "#/definitions/ErrorResponse"
  8410          503:
  8411            description: "node is not part of a swarm"
  8412            schema:
  8413              $ref: "#/definitions/ErrorResponse"
  8414        parameters:
  8415          - name: "filters"
  8416            in: "query"
  8417            description: |
  8418              Filters to process on the nodes list, encoded as JSON (a `map[string][]string`).
  8419  
  8420              Available filters:
  8421              - `id=<node id>`
  8422              - `label=<engine label>`
  8423              - `membership=`(`accepted`|`pending`)`
  8424              - `name=<node name>`
  8425              - `role=`(`manager`|`worker`)`
  8426            type: "string"
  8427        tags: ["Node"]
  8428    /nodes/{id}:
  8429      get:
  8430        summary: "Inspect a node"
  8431        operationId: "NodeInspect"
  8432        responses:
  8433          200:
  8434            description: "no error"
  8435            schema:
  8436              $ref: "#/definitions/Node"
  8437          404:
  8438            description: "no such node"
  8439            schema:
  8440              $ref: "#/definitions/ErrorResponse"
  8441          500:
  8442            description: "server error"
  8443            schema:
  8444              $ref: "#/definitions/ErrorResponse"
  8445          503:
  8446            description: "node is not part of a swarm"
  8447            schema:
  8448              $ref: "#/definitions/ErrorResponse"
  8449        parameters:
  8450          - name: "id"
  8451            in: "path"
  8452            description: "The ID or name of the node"
  8453            type: "string"
  8454            required: true
  8455        tags: ["Node"]
  8456      delete:
  8457        summary: "Delete a node"
  8458        operationId: "NodeDelete"
  8459        responses:
  8460          200:
  8461            description: "no error"
  8462          404:
  8463            description: "no such node"
  8464            schema:
  8465              $ref: "#/definitions/ErrorResponse"
  8466          500:
  8467            description: "server error"
  8468            schema:
  8469              $ref: "#/definitions/ErrorResponse"
  8470          503:
  8471            description: "node is not part of a swarm"
  8472            schema:
  8473              $ref: "#/definitions/ErrorResponse"
  8474        parameters:
  8475          - name: "id"
  8476            in: "path"
  8477            description: "The ID or name of the node"
  8478            type: "string"
  8479            required: true
  8480          - name: "force"
  8481            in: "query"
  8482            description: "Force remove a node from the swarm"
  8483            default: false
  8484            type: "boolean"
  8485        tags: ["Node"]
  8486    /nodes/{id}/update:
  8487      post:
  8488        summary: "Update a node"
  8489        operationId: "NodeUpdate"
  8490        responses:
  8491          200:
  8492            description: "no error"
  8493          400:
  8494            description: "bad parameter"
  8495            schema:
  8496              $ref: "#/definitions/ErrorResponse"
  8497          404:
  8498            description: "no such node"
  8499            schema:
  8500              $ref: "#/definitions/ErrorResponse"
  8501          500:
  8502            description: "server error"
  8503            schema:
  8504              $ref: "#/definitions/ErrorResponse"
  8505          503:
  8506            description: "node is not part of a swarm"
  8507            schema:
  8508              $ref: "#/definitions/ErrorResponse"
  8509        parameters:
  8510          - name: "id"
  8511            in: "path"
  8512            description: "The ID of the node"
  8513            type: "string"
  8514            required: true
  8515          - name: "body"
  8516            in: "body"
  8517            schema:
  8518              $ref: "#/definitions/NodeSpec"
  8519          - name: "version"
  8520            in: "query"
  8521            description: "The version number of the node object being updated. This is required to avoid conflicting writes."
  8522            type: "integer"
  8523            format: "int64"
  8524            required: true
  8525        tags: ["Node"]
  8526    /swarm:
  8527      get:
  8528        summary: "Inspect swarm"
  8529        operationId: "SwarmInspect"
  8530        responses:
  8531          200:
  8532            description: "no error"
  8533            schema:
  8534              $ref: "#/definitions/Swarm"
  8535          404:
  8536            description: "no such swarm"
  8537            schema:
  8538              $ref: "#/definitions/ErrorResponse"
  8539          500:
  8540            description: "server error"
  8541            schema:
  8542              $ref: "#/definitions/ErrorResponse"
  8543          503:
  8544            description: "node is not part of a swarm"
  8545            schema:
  8546              $ref: "#/definitions/ErrorResponse"
  8547        tags: ["Swarm"]
  8548    /swarm/init:
  8549      post:
  8550        summary: "Initialize a new swarm"
  8551        operationId: "SwarmInit"
  8552        produces:
  8553          - "application/json"
  8554          - "text/plain"
  8555        responses:
  8556          200:
  8557            description: "no error"
  8558            schema:
  8559              description: "The node ID"
  8560              type: "string"
  8561              example: "7v2t30z9blmxuhnyo6s4cpenp"
  8562          400:
  8563            description: "bad parameter"
  8564            schema:
  8565              $ref: "#/definitions/ErrorResponse"
  8566          500:
  8567            description: "server error"
  8568            schema:
  8569              $ref: "#/definitions/ErrorResponse"
  8570          503:
  8571            description: "node is already part of a swarm"
  8572            schema:
  8573              $ref: "#/definitions/ErrorResponse"
  8574        parameters:
  8575          - name: "body"
  8576            in: "body"
  8577            required: true
  8578            schema:
  8579              type: "object"
  8580              properties:
  8581                ListenAddr:
  8582                  description: "Listen address used for inter-manager communication, as well as determining the networking interface used for the VXLAN Tunnel Endpoint (VTEP). This can either be an address/port combination in the form `192.168.1.1:4567`, or an interface followed by a port number, like `eth0:4567`. If the port number is omitted, the default swarm listening port is used."
  8583                  type: "string"
  8584                AdvertiseAddr:
  8585                  description: "Externally reachable address advertised to other nodes. This can either be an address/port combination in the form `192.168.1.1:4567`, or an interface followed by a port number, like `eth0:4567`. If the port number is omitted, the port number from the listen address is used. If `AdvertiseAddr` is not specified, it will be automatically detected when possible."
  8586                  type: "string"
  8587                DataPathAddr:
  8588                  description: |
  8589                    Address or interface to use for data path traffic (format: `<ip|interface>`), for example,  `192.168.1.1`,
  8590                    or an interface, like `eth0`. If `DataPathAddr` is unspecified, the same address as `AdvertiseAddr`
  8591                    is used.
  8592  
  8593                    The `DataPathAddr` specifies the address that global scope network drivers will publish towards other
  8594                    nodes in order to reach the containers running on this node. Using this parameter it is possible to
  8595                    separate the container data traffic from the management traffic of the cluster.
  8596                  type: "string"
  8597                ForceNewCluster:
  8598                  description: "Force creation of a new swarm."
  8599                  type: "boolean"
  8600                Spec:
  8601                  $ref: "#/definitions/SwarmSpec"
  8602              example:
  8603                ListenAddr: "0.0.0.0:2377"
  8604                AdvertiseAddr: "192.168.1.1:2377"
  8605                ForceNewCluster: false
  8606                Spec:
  8607                  Orchestration: {}
  8608                  Raft: {}
  8609                  Dispatcher: {}
  8610                  CAConfig: {}
  8611                  EncryptionConfig:
  8612                    AutoLockManagers: false
  8613        tags: ["Swarm"]
  8614    /swarm/join:
  8615      post:
  8616        summary: "Join an existing swarm"
  8617        operationId: "SwarmJoin"
  8618        responses:
  8619          200:
  8620            description: "no error"
  8621          400:
  8622            description: "bad parameter"
  8623            schema:
  8624              $ref: "#/definitions/ErrorResponse"
  8625          500:
  8626            description: "server error"
  8627            schema:
  8628              $ref: "#/definitions/ErrorResponse"
  8629          503:
  8630            description: "node is already part of a swarm"
  8631            schema:
  8632              $ref: "#/definitions/ErrorResponse"
  8633        parameters:
  8634          - name: "body"
  8635            in: "body"
  8636            required: true
  8637            schema:
  8638              type: "object"
  8639              properties:
  8640                ListenAddr:
  8641                  description: "Listen address used for inter-manager communication if the node gets promoted to manager, as well as determining the networking interface used for the VXLAN Tunnel Endpoint (VTEP)."
  8642                  type: "string"
  8643                AdvertiseAddr:
  8644                  description: "Externally reachable address advertised to other nodes. This can either be an address/port combination in the form `192.168.1.1:4567`, or an interface followed by a port number, like `eth0:4567`. If the port number is omitted, the port number from the listen address is used. If `AdvertiseAddr` is not specified, it will be automatically detected when possible."
  8645                  type: "string"
  8646                DataPathAddr:
  8647                  description: |
  8648                    Address or interface to use for data path traffic (format: `<ip|interface>`), for example,  `192.168.1.1`,
  8649                    or an interface, like `eth0`. If `DataPathAddr` is unspecified, the same address as `AdvertiseAddr`
  8650                    is used.
  8651  
  8652                    The `DataPathAddr` specifies the address that global scope network drivers will publish towards other
  8653                    nodes in order to reach the containers running on this node. Using this parameter it is possible to
  8654                    separate the container data traffic from the management traffic of the cluster.
  8655  
  8656                  type: "string"
  8657                RemoteAddrs:
  8658                  description: "Addresses of manager nodes already participating in the swarm."
  8659                  type: "string"
  8660                JoinToken:
  8661                  description: "Secret token for joining this swarm."
  8662                  type: "string"
  8663              example:
  8664                ListenAddr: "0.0.0.0:2377"
  8665                AdvertiseAddr: "192.168.1.1:2377"
  8666                RemoteAddrs:
  8667                  - "node1:2377"
  8668                JoinToken: "SWMTKN-1-3pu6hszjas19xyp7ghgosyx9k8atbfcr8p2is99znpy26u2lkl-7p73s1dx5in4tatdymyhg9hu2"
  8669        tags: ["Swarm"]
  8670    /swarm/leave:
  8671      post:
  8672        summary: "Leave a swarm"
  8673        operationId: "SwarmLeave"
  8674        responses:
  8675          200:
  8676            description: "no error"
  8677          500:
  8678            description: "server error"
  8679            schema:
  8680              $ref: "#/definitions/ErrorResponse"
  8681          503:
  8682            description: "node is not part of a swarm"
  8683            schema:
  8684              $ref: "#/definitions/ErrorResponse"
  8685        parameters:
  8686          - name: "force"
  8687            description: "Force leave swarm, even if this is the last manager or that it will break the cluster."
  8688            in: "query"
  8689            type: "boolean"
  8690            default: false
  8691        tags: ["Swarm"]
  8692    /swarm/update:
  8693      post:
  8694        summary: "Update a swarm"
  8695        operationId: "SwarmUpdate"
  8696        responses:
  8697          200:
  8698            description: "no error"
  8699          400:
  8700            description: "bad parameter"
  8701            schema:
  8702              $ref: "#/definitions/ErrorResponse"
  8703          500:
  8704            description: "server error"
  8705            schema:
  8706              $ref: "#/definitions/ErrorResponse"
  8707          503:
  8708            description: "node is not part of a swarm"
  8709            schema:
  8710              $ref: "#/definitions/ErrorResponse"
  8711        parameters:
  8712          - name: "body"
  8713            in: "body"
  8714            required: true
  8715            schema:
  8716              $ref: "#/definitions/SwarmSpec"
  8717          - name: "version"
  8718            in: "query"
  8719            description: "The version number of the swarm object being updated. This is required to avoid conflicting writes."
  8720            type: "integer"
  8721            format: "int64"
  8722            required: true
  8723          - name: "rotateWorkerToken"
  8724            in: "query"
  8725            description: "Rotate the worker join token."
  8726            type: "boolean"
  8727            default: false
  8728          - name: "rotateManagerToken"
  8729            in: "query"
  8730            description: "Rotate the manager join token."
  8731            type: "boolean"
  8732            default: false
  8733          - name: "rotateManagerUnlockKey"
  8734            in: "query"
  8735            description: "Rotate the manager unlock key."
  8736            type: "boolean"
  8737            default: false
  8738        tags: ["Swarm"]
  8739    /swarm/unlockkey:
  8740      get:
  8741        summary: "Get the unlock key"
  8742        operationId: "SwarmUnlockkey"
  8743        consumes:
  8744          - "application/json"
  8745        responses:
  8746          200:
  8747            description: "no error"
  8748            schema:
  8749              type: "object"
  8750              properties:
  8751                UnlockKey:
  8752                  description: "The swarm's unlock key."
  8753                  type: "string"
  8754              example:
  8755                UnlockKey: "SWMKEY-1-7c37Cc8654o6p38HnroywCi19pllOnGtbdZEgtKxZu8"
  8756          500:
  8757            description: "server error"
  8758            schema:
  8759              $ref: "#/definitions/ErrorResponse"
  8760          503:
  8761            description: "node is not part of a swarm"
  8762            schema:
  8763              $ref: "#/definitions/ErrorResponse"
  8764        tags: ["Swarm"]
  8765    /swarm/unlock:
  8766      post:
  8767        summary: "Unlock a locked manager"
  8768        operationId: "SwarmUnlock"
  8769        consumes:
  8770          - "application/json"
  8771        produces:
  8772          - "application/json"
  8773        parameters:
  8774          - name: "body"
  8775            in: "body"
  8776            required: true
  8777            schema:
  8778              type: "object"
  8779              properties:
  8780                UnlockKey:
  8781                  description: "The swarm's unlock key."
  8782                  type: "string"
  8783              example:
  8784                UnlockKey: "SWMKEY-1-7c37Cc8654o6p38HnroywCi19pllOnGtbdZEgtKxZu8"
  8785        responses:
  8786          200:
  8787            description: "no error"
  8788          500:
  8789            description: "server error"
  8790            schema:
  8791              $ref: "#/definitions/ErrorResponse"
  8792          503:
  8793            description: "node is not part of a swarm"
  8794            schema:
  8795              $ref: "#/definitions/ErrorResponse"
  8796        tags: ["Swarm"]
  8797    /services:
  8798      get:
  8799        summary: "List services"
  8800        operationId: "ServiceList"
  8801        responses:
  8802          200:
  8803            description: "no error"
  8804            schema:
  8805              type: "array"
  8806              items:
  8807                $ref: "#/definitions/Service"
  8808          500:
  8809            description: "server error"
  8810            schema:
  8811              $ref: "#/definitions/ErrorResponse"
  8812          503:
  8813            description: "node is not part of a swarm"
  8814            schema:
  8815              $ref: "#/definitions/ErrorResponse"
  8816        parameters:
  8817          - name: "filters"
  8818            in: "query"
  8819            type: "string"
  8820            description: |
  8821              A JSON encoded value of the filters (a `map[string][]string`) to process on the services list. Available filters:
  8822  
  8823              - `id=<service id>`
  8824              - `label=<service label>`
  8825              - `mode=["replicated"|"global"]`
  8826              - `name=<service name>`
  8827        tags: ["Service"]
  8828    /services/create:
  8829      post:
  8830        summary: "Create a service"
  8831        operationId: "ServiceCreate"
  8832        consumes:
  8833          - "application/json"
  8834        produces:
  8835          - "application/json"
  8836        responses:
  8837          201:
  8838            description: "no error"
  8839            schema:
  8840              type: "object"
  8841              properties:
  8842                ID:
  8843                  description: "The ID of the created service."
  8844                  type: "string"
  8845                Warning:
  8846                  description: "Optional warning message"
  8847                  type: "string"
  8848              example:
  8849                ID: "ak7w3gjqoa3kuz8xcpnyy0pvl"
  8850                Warning: "unable to pin image doesnotexist:latest to digest: image library/doesnotexist:latest not found"
  8851          400:
  8852            description: "bad parameter"
  8853            schema:
  8854              $ref: "#/definitions/ErrorResponse"
  8855          403:
  8856            description: "network is not eligible for services"
  8857            schema:
  8858              $ref: "#/definitions/ErrorResponse"
  8859          409:
  8860            description: "name conflicts with an existing service"
  8861            schema:
  8862              $ref: "#/definitions/ErrorResponse"
  8863          500:
  8864            description: "server error"
  8865            schema:
  8866              $ref: "#/definitions/ErrorResponse"
  8867          503:
  8868            description: "node is not part of a swarm"
  8869            schema:
  8870              $ref: "#/definitions/ErrorResponse"
  8871        parameters:
  8872          - name: "body"
  8873            in: "body"
  8874            required: true
  8875            schema:
  8876              allOf:
  8877                - $ref: "#/definitions/ServiceSpec"
  8878                - type: "object"
  8879                  example:
  8880                    Name: "web"
  8881                    TaskTemplate:
  8882                      ContainerSpec:
  8883                        Image: "nginx:alpine"
  8884                        Mounts:
  8885                          -
  8886                            ReadOnly: true
  8887                            Source: "web-data"
  8888                            Target: "/usr/share/nginx/html"
  8889                            Type: "volume"
  8890                            VolumeOptions:
  8891                              DriverConfig: {}
  8892                              Labels:
  8893                                com.example.something: "something-value"
  8894                        Hosts: ["10.10.10.10 host1", "ABCD:EF01:2345:6789:ABCD:EF01:2345:6789 host2"]
  8895                        User: "33"
  8896                        DNSConfig:
  8897                          Nameservers: ["8.8.8.8"]
  8898                          Search: ["example.org"]
  8899                          Options: ["timeout:3"]
  8900                        Secrets:
  8901                          -
  8902                            File:
  8903                              Name: "www.example.org.key"
  8904                              UID: "33"
  8905                              GID: "33"
  8906                              Mode: 384
  8907                            SecretID: "fpjqlhnwb19zds35k8wn80lq9"
  8908                            SecretName: "example_org_domain_key"
  8909                      LogDriver:
  8910                        Name: "json-file"
  8911                        Options:
  8912                          max-file: "3"
  8913                          max-size: "10M"
  8914                      Placement: {}
  8915                      Resources:
  8916                        Limits:
  8917                          MemoryBytes: 104857600
  8918                        Reservations: {}
  8919                      RestartPolicy:
  8920                        Condition: "on-failure"
  8921                        Delay: 10000000000
  8922                        MaxAttempts: 10
  8923                    Mode:
  8924                      Replicated:
  8925                        Replicas: 4
  8926                    UpdateConfig:
  8927                      Parallelism: 2
  8928                      Delay: 1000000000
  8929                      FailureAction: "pause"
  8930                      Monitor: 15000000000
  8931                      MaxFailureRatio: 0.15
  8932                    RollbackConfig:
  8933                      Parallelism: 1
  8934                      Delay: 1000000000
  8935                      FailureAction: "pause"
  8936                      Monitor: 15000000000
  8937                      MaxFailureRatio: 0.15
  8938                    EndpointSpec:
  8939                      Ports:
  8940                        -
  8941                          Protocol: "tcp"
  8942                          PublishedPort: 8080
  8943                          TargetPort: 80
  8944                    Labels:
  8945                      foo: "bar"
  8946          - name: "X-Registry-Auth"
  8947            in: "header"
  8948            description: "A base64-encoded auth configuration for pulling from private registries. [See the authentication section for details.](#section/Authentication)"
  8949            type: "string"
  8950        tags: ["Service"]
  8951    /services/{id}:
  8952      get:
  8953        summary: "Inspect a service"
  8954        operationId: "ServiceInspect"
  8955        responses:
  8956          200:
  8957            description: "no error"
  8958            schema:
  8959              $ref: "#/definitions/Service"
  8960          404:
  8961            description: "no such service"
  8962            schema:
  8963              $ref: "#/definitions/ErrorResponse"
  8964          500:
  8965            description: "server error"
  8966            schema:
  8967              $ref: "#/definitions/ErrorResponse"
  8968          503:
  8969            description: "node is not part of a swarm"
  8970            schema:
  8971              $ref: "#/definitions/ErrorResponse"
  8972        parameters:
  8973          - name: "id"
  8974            in: "path"
  8975            description: "ID or name of service."
  8976            required: true
  8977            type: "string"
  8978          - name: "insertDefaults"
  8979            in: "query"
  8980            description: "Fill empty fields with default values."
  8981            type: "boolean"
  8982            default: false
  8983        tags: ["Service"]
  8984      delete:
  8985        summary: "Delete a service"
  8986        operationId: "ServiceDelete"
  8987        responses:
  8988          200:
  8989            description: "no error"
  8990          404:
  8991            description: "no such service"
  8992            schema:
  8993              $ref: "#/definitions/ErrorResponse"
  8994          500:
  8995            description: "server error"
  8996            schema:
  8997              $ref: "#/definitions/ErrorResponse"
  8998          503:
  8999            description: "node is not part of a swarm"
  9000            schema:
  9001              $ref: "#/definitions/ErrorResponse"
  9002        parameters:
  9003          - name: "id"
  9004            in: "path"
  9005            description: "ID or name of service."
  9006            required: true
  9007            type: "string"
  9008        tags: ["Service"]
  9009    /services/{id}/update:
  9010      post:
  9011        summary: "Update a service"
  9012        operationId: "ServiceUpdate"
  9013        consumes: ["application/json"]
  9014        produces: ["application/json"]
  9015        responses:
  9016          200:
  9017            description: "no error"
  9018            schema:
  9019              $ref: "#/definitions/ServiceUpdateResponse"
  9020          400:
  9021            description: "bad parameter"
  9022            schema:
  9023              $ref: "#/definitions/ErrorResponse"
  9024          404:
  9025            description: "no such service"
  9026            schema:
  9027              $ref: "#/definitions/ErrorResponse"
  9028          500:
  9029            description: "server error"
  9030            schema:
  9031              $ref: "#/definitions/ErrorResponse"
  9032          503:
  9033            description: "node is not part of a swarm"
  9034            schema:
  9035              $ref: "#/definitions/ErrorResponse"
  9036        parameters:
  9037          - name: "id"
  9038            in: "path"
  9039            description: "ID or name of service."
  9040            required: true
  9041            type: "string"
  9042          - name: "body"
  9043            in: "body"
  9044            required: true
  9045            schema:
  9046              allOf:
  9047                - $ref: "#/definitions/ServiceSpec"
  9048                - type: "object"
  9049                  example:
  9050                    Name: "top"
  9051                    TaskTemplate:
  9052                      ContainerSpec:
  9053                        Image: "busybox"
  9054                        Args:
  9055                          - "top"
  9056                      Resources:
  9057                        Limits: {}
  9058                        Reservations: {}
  9059                      RestartPolicy:
  9060                        Condition: "any"
  9061                        MaxAttempts: 0
  9062                      Placement: {}
  9063                      ForceUpdate: 0
  9064                    Mode:
  9065                      Replicated:
  9066                        Replicas: 1
  9067                    UpdateConfig:
  9068                      Parallelism: 2
  9069                      Delay: 1000000000
  9070                      FailureAction: "pause"
  9071                      Monitor: 15000000000
  9072                      MaxFailureRatio: 0.15
  9073                    RollbackConfig:
  9074                      Parallelism: 1
  9075                      Delay: 1000000000
  9076                      FailureAction: "pause"
  9077                      Monitor: 15000000000
  9078                      MaxFailureRatio: 0.15
  9079                    EndpointSpec:
  9080                      Mode: "vip"
  9081  
  9082          - name: "version"
  9083            in: "query"
  9084            description: "The version number of the service object being updated. This is required to avoid conflicting writes."
  9085            required: true
  9086            type: "integer"
  9087          - name: "registryAuthFrom"
  9088            in: "query"
  9089            type: "string"
  9090            description: "If the X-Registry-Auth header is not specified, this
  9091    parameter indicates where to find registry authorization credentials. The
  9092    valid values are `spec` and `previous-spec`."
  9093            default: "spec"
  9094          - name: "rollback"
  9095            in: "query"
  9096            type: "string"
  9097            description: "Set to this parameter to `previous` to cause a
  9098    server-side rollback to the previous service spec. The supplied spec will be
  9099    ignored in this case."
  9100          - name: "X-Registry-Auth"
  9101            in: "header"
  9102            description: "A base64-encoded auth configuration for pulling from private registries. [See the authentication section for details.](#section/Authentication)"
  9103            type: "string"
  9104  
  9105        tags: ["Service"]
  9106    /services/{id}/logs:
  9107      get:
  9108        summary: "Get service logs"
  9109        description: |
  9110          Get `stdout` and `stderr` logs from a service.
  9111  
  9112          **Note**: This endpoint works only for services with the `json-file` or `journald` logging drivers.
  9113        operationId: "ServiceLogs"
  9114        produces:
  9115          - "application/vnd.docker.raw-stream"
  9116          - "application/json"
  9117        responses:
  9118          101:
  9119            description: "logs returned as a stream"
  9120            schema:
  9121              type: "string"
  9122              format: "binary"
  9123          200:
  9124            description: "logs returned as a string in response body"
  9125            schema:
  9126              type: "string"
  9127          404:
  9128            description: "no such service"
  9129            schema:
  9130              $ref: "#/definitions/ErrorResponse"
  9131            examples:
  9132              application/json:
  9133                message: "No such service: c2ada9df5af8"
  9134          500:
  9135            description: "server error"
  9136            schema:
  9137              $ref: "#/definitions/ErrorResponse"
  9138          503:
  9139            description: "node is not part of a swarm"
  9140            schema:
  9141              $ref: "#/definitions/ErrorResponse"
  9142        parameters:
  9143          - name: "id"
  9144            in: "path"
  9145            required: true
  9146            description: "ID or name of the service"
  9147            type: "string"
  9148          - name: "details"
  9149            in: "query"
  9150            description: "Show service context and extra details provided to logs."
  9151            type: "boolean"
  9152            default: false
  9153          - name: "follow"
  9154            in: "query"
  9155            description: |
  9156              Return the logs as a stream.
  9157  
  9158              This will return a `101` HTTP response with a `Connection: upgrade` header, then hijack the HTTP connection to send raw output. For more information about hijacking and the stream format, [see the documentation for the attach endpoint](#operation/ContainerAttach).
  9159            type: "boolean"
  9160            default: false
  9161          - name: "stdout"
  9162            in: "query"
  9163            description: "Return logs from `stdout`"
  9164            type: "boolean"
  9165            default: false
  9166          - name: "stderr"
  9167            in: "query"
  9168            description: "Return logs from `stderr`"
  9169            type: "boolean"
  9170            default: false
  9171          - name: "since"
  9172            in: "query"
  9173            description: "Only return logs since this time, as a UNIX timestamp"
  9174            type: "integer"
  9175            default: 0
  9176          - name: "timestamps"
  9177            in: "query"
  9178            description: "Add timestamps to every log line"
  9179            type: "boolean"
  9180            default: false
  9181          - name: "tail"
  9182            in: "query"
  9183            description: "Only return this number of log lines from the end of the logs. Specify as an integer or `all` to output all log lines."
  9184            type: "string"
  9185            default: "all"
  9186        tags: ["Service"]
  9187    /tasks:
  9188      get:
  9189        summary: "List tasks"
  9190        operationId: "TaskList"
  9191        produces:
  9192          - "application/json"
  9193        responses:
  9194          200:
  9195            description: "no error"
  9196            schema:
  9197              type: "array"
  9198              items:
  9199                $ref: "#/definitions/Task"
  9200              example:
  9201                - ID: "0kzzo1i0y4jz6027t0k7aezc7"
  9202                  Version:
  9203                    Index: 71
  9204                  CreatedAt: "2016-06-07T21:07:31.171892745Z"
  9205                  UpdatedAt: "2016-06-07T21:07:31.376370513Z"
  9206                  Spec:
  9207                    ContainerSpec:
  9208                      Image: "redis"
  9209                    Resources:
  9210                      Limits: {}
  9211                      Reservations: {}
  9212                    RestartPolicy:
  9213                      Condition: "any"
  9214                      MaxAttempts: 0
  9215                    Placement: {}
  9216                  ServiceID: "9mnpnzenvg8p8tdbtq4wvbkcz"
  9217                  Slot: 1
  9218                  NodeID: "60gvrl6tm78dmak4yl7srz94v"
  9219                  Status:
  9220                    Timestamp: "2016-06-07T21:07:31.290032978Z"
  9221                    State: "running"
  9222                    Message: "started"
  9223                    ContainerStatus:
  9224                      ContainerID: "e5d62702a1b48d01c3e02ca1e0212a250801fa8d67caca0b6f35919ebc12f035"
  9225                      PID: 677
  9226                  DesiredState: "running"
  9227                  NetworksAttachments:
  9228                    - Network:
  9229                        ID: "4qvuz4ko70xaltuqbt8956gd1"
  9230                        Version:
  9231                          Index: 18
  9232                        CreatedAt: "2016-06-07T20:31:11.912919752Z"
  9233                        UpdatedAt: "2016-06-07T21:07:29.955277358Z"
  9234                        Spec:
  9235                          Name: "ingress"
  9236                          Labels:
  9237                            com.docker.swarm.internal: "true"
  9238                          DriverConfiguration: {}
  9239                          IPAMOptions:
  9240                            Driver: {}
  9241                            Configs:
  9242                              - Subnet: "10.255.0.0/16"
  9243                                Gateway: "10.255.0.1"
  9244                        DriverState:
  9245                          Name: "overlay"
  9246                          Options:
  9247                            com.docker.network.driver.overlay.vxlanid_list: "256"
  9248                        IPAMOptions:
  9249                          Driver:
  9250                            Name: "default"
  9251                          Configs:
  9252                            - Subnet: "10.255.0.0/16"
  9253                              Gateway: "10.255.0.1"
  9254                      Addresses:
  9255                        - "10.255.0.10/16"
  9256                - ID: "1yljwbmlr8er2waf8orvqpwms"
  9257                  Version:
  9258                    Index: 30
  9259                  CreatedAt: "2016-06-07T21:07:30.019104782Z"
  9260                  UpdatedAt: "2016-06-07T21:07:30.231958098Z"
  9261                  Name: "hopeful_cori"
  9262                  Spec:
  9263                    ContainerSpec:
  9264                      Image: "redis"
  9265                    Resources:
  9266                      Limits: {}
  9267                      Reservations: {}
  9268                    RestartPolicy:
  9269                      Condition: "any"
  9270                      MaxAttempts: 0
  9271                    Placement: {}
  9272                  ServiceID: "9mnpnzenvg8p8tdbtq4wvbkcz"
  9273                  Slot: 1
  9274                  NodeID: "60gvrl6tm78dmak4yl7srz94v"
  9275                  Status:
  9276                    Timestamp: "2016-06-07T21:07:30.202183143Z"
  9277                    State: "shutdown"
  9278                    Message: "shutdown"
  9279                    ContainerStatus:
  9280                      ContainerID: "1cf8d63d18e79668b0004a4be4c6ee58cddfad2dae29506d8781581d0688a213"
  9281                  DesiredState: "shutdown"
  9282                  NetworksAttachments:
  9283                    - Network:
  9284                        ID: "4qvuz4ko70xaltuqbt8956gd1"
  9285                        Version:
  9286                          Index: 18
  9287                        CreatedAt: "2016-06-07T20:31:11.912919752Z"
  9288                        UpdatedAt: "2016-06-07T21:07:29.955277358Z"
  9289                        Spec:
  9290                          Name: "ingress"
  9291                          Labels:
  9292                            com.docker.swarm.internal: "true"
  9293                          DriverConfiguration: {}
  9294                          IPAMOptions:
  9295                            Driver: {}
  9296                            Configs:
  9297                              - Subnet: "10.255.0.0/16"
  9298                                Gateway: "10.255.0.1"
  9299                        DriverState:
  9300                          Name: "overlay"
  9301                          Options:
  9302                            com.docker.network.driver.overlay.vxlanid_list: "256"
  9303                        IPAMOptions:
  9304                          Driver:
  9305                            Name: "default"
  9306                          Configs:
  9307                            - Subnet: "10.255.0.0/16"
  9308                              Gateway: "10.255.0.1"
  9309                      Addresses:
  9310                        - "10.255.0.5/16"
  9311          500:
  9312            description: "server error"
  9313            schema:
  9314              $ref: "#/definitions/ErrorResponse"
  9315          503:
  9316            description: "node is not part of a swarm"
  9317            schema:
  9318              $ref: "#/definitions/ErrorResponse"
  9319        parameters:
  9320          - name: "filters"
  9321            in: "query"
  9322            type: "string"
  9323            description: |
  9324              A JSON encoded value of the filters (a `map[string][]string`) to process on the tasks list. Available filters:
  9325  
  9326              - `desired-state=(running | shutdown | accepted)`
  9327              - `id=<task id>`
  9328              - `label=key` or `label="key=value"`
  9329              - `name=<task name>`
  9330              - `node=<node id or name>`
  9331              - `service=<service name>`
  9332        tags: ["Task"]
  9333    /tasks/{id}:
  9334      get:
  9335        summary: "Inspect a task"
  9336        operationId: "TaskInspect"
  9337        produces:
  9338          - "application/json"
  9339        responses:
  9340          200:
  9341            description: "no error"
  9342            schema:
  9343              $ref: "#/definitions/Task"
  9344          404:
  9345            description: "no such task"
  9346            schema:
  9347              $ref: "#/definitions/ErrorResponse"
  9348          500:
  9349            description: "server error"
  9350            schema:
  9351              $ref: "#/definitions/ErrorResponse"
  9352          503:
  9353            description: "node is not part of a swarm"
  9354            schema:
  9355              $ref: "#/definitions/ErrorResponse"
  9356        parameters:
  9357          - name: "id"
  9358            in: "path"
  9359            description: "ID of the task"
  9360            required: true
  9361            type: "string"
  9362        tags: ["Task"]
  9363    /tasks/{id}/logs:
  9364      get:
  9365        summary: "Get task logs"
  9366        description: |
  9367          Get `stdout` and `stderr` logs from a task.
  9368  
  9369          **Note**: This endpoint works only for services with the `json-file` or `journald` logging drivers.
  9370        operationId: "TaskLogs"
  9371        produces:
  9372          - "application/vnd.docker.raw-stream"
  9373          - "application/json"
  9374        responses:
  9375          101:
  9376            description: "logs returned as a stream"
  9377            schema:
  9378              type: "string"
  9379              format: "binary"
  9380          200:
  9381            description: "logs returned as a string in response body"
  9382            schema:
  9383              type: "string"
  9384          404:
  9385            description: "no such task"
  9386            schema:
  9387              $ref: "#/definitions/ErrorResponse"
  9388            examples:
  9389              application/json:
  9390                message: "No such task: c2ada9df5af8"
  9391          500:
  9392            description: "server error"
  9393            schema:
  9394              $ref: "#/definitions/ErrorResponse"
  9395          503:
  9396            description: "node is not part of a swarm"
  9397            schema:
  9398              $ref: "#/definitions/ErrorResponse"
  9399        parameters:
  9400          - name: "id"
  9401            in: "path"
  9402            required: true
  9403            description: "ID of the task"
  9404            type: "string"
  9405          - name: "details"
  9406            in: "query"
  9407            description: "Show task context and extra details provided to logs."
  9408            type: "boolean"
  9409            default: false
  9410          - name: "follow"
  9411            in: "query"
  9412            description: |
  9413              Return the logs as a stream.
  9414  
  9415              This will return a `101` HTTP response with a `Connection: upgrade` header, then hijack the HTTP connection to send raw output. For more information about hijacking and the stream format, [see the documentation for the attach endpoint](#operation/ContainerAttach).
  9416            type: "boolean"
  9417            default: false
  9418          - name: "stdout"
  9419            in: "query"
  9420            description: "Return logs from `stdout`"
  9421            type: "boolean"
  9422            default: false
  9423          - name: "stderr"
  9424            in: "query"
  9425            description: "Return logs from `stderr`"
  9426            type: "boolean"
  9427            default: false
  9428          - name: "since"
  9429            in: "query"
  9430            description: "Only return logs since this time, as a UNIX timestamp"
  9431            type: "integer"
  9432            default: 0
  9433          - name: "timestamps"
  9434            in: "query"
  9435            description: "Add timestamps to every log line"
  9436            type: "boolean"
  9437            default: false
  9438          - name: "tail"
  9439            in: "query"
  9440            description: "Only return this number of log lines from the end of the logs. Specify as an integer or `all` to output all log lines."
  9441            type: "string"
  9442            default: "all"
  9443    /secrets:
  9444      get:
  9445        summary: "List secrets"
  9446        operationId: "SecretList"
  9447        produces:
  9448          - "application/json"
  9449        responses:
  9450          200:
  9451            description: "no error"
  9452            schema:
  9453              type: "array"
  9454              items:
  9455                $ref: "#/definitions/Secret"
  9456              example:
  9457                - ID: "blt1owaxmitz71s9v5zh81zun"
  9458                  Version:
  9459                    Index: 85
  9460                  CreatedAt: "2017-07-20T13:55:28.678958722Z"
  9461                  UpdatedAt: "2017-07-20T13:55:28.678958722Z"
  9462                  Spec:
  9463                    Name: "mysql-passwd"
  9464                    Labels:
  9465                      some.label: "some.value"
  9466                    Driver:
  9467                      Name: "secret-bucket"
  9468                      Options:
  9469                        OptionA: "value for driver option A"
  9470                        OptionB: "value for driver option B"
  9471                - ID: "ktnbjxoalbkvbvedmg1urrz8h"
  9472                  Version:
  9473                    Index: 11
  9474                  CreatedAt: "2016-11-05T01:20:17.327670065Z"
  9475                  UpdatedAt: "2016-11-05T01:20:17.327670065Z"
  9476                  Spec:
  9477                    Name: "app-dev.crt"
  9478                    Labels:
  9479                      foo: "bar"
  9480          500:
  9481            description: "server error"
  9482            schema:
  9483              $ref: "#/definitions/ErrorResponse"
  9484          503:
  9485            description: "node is not part of a swarm"
  9486            schema:
  9487              $ref: "#/definitions/ErrorResponse"
  9488        parameters:
  9489          - name: "filters"
  9490            in: "query"
  9491            type: "string"
  9492            description: |
  9493              A JSON encoded value of the filters (a `map[string][]string`) to process on the secrets list. Available filters:
  9494  
  9495              - `id=<secret id>`
  9496              - `label=<key> or label=<key>=value`
  9497              - `name=<secret name>`
  9498              - `names=<secret name>`
  9499        tags: ["Secret"]
  9500    /secrets/create:
  9501      post:
  9502        summary: "Create a secret"
  9503        operationId: "SecretCreate"
  9504        consumes:
  9505          - "application/json"
  9506        produces:
  9507          - "application/json"
  9508        responses:
  9509          201:
  9510            description: "no error"
  9511            schema:
  9512              type: "object"
  9513              properties:
  9514                ID:
  9515                  description: "The ID of the created secret."
  9516                  type: "string"
  9517              example:
  9518                ID: "ktnbjxoalbkvbvedmg1urrz8h"
  9519          409:
  9520            description: "name conflicts with an existing object"
  9521            schema:
  9522              $ref: "#/definitions/ErrorResponse"
  9523          500:
  9524            description: "server error"
  9525            schema:
  9526              $ref: "#/definitions/ErrorResponse"
  9527          503:
  9528            description: "node is not part of a swarm"
  9529            schema:
  9530              $ref: "#/definitions/ErrorResponse"
  9531        parameters:
  9532          - name: "body"
  9533            in: "body"
  9534            schema:
  9535              allOf:
  9536                - $ref: "#/definitions/SecretSpec"
  9537                - type: "object"
  9538                  example:
  9539                    Name: "app-key.crt"
  9540                    Labels:
  9541                      foo: "bar"
  9542                    Data: "VEhJUyBJUyBOT1QgQSBSRUFMIENFUlRJRklDQVRFCg=="
  9543                    Driver:
  9544                      Name: "secret-bucket"
  9545                      Options:
  9546                        OptionA: "value for driver option A"
  9547                        OptionB: "value for driver option B"
  9548        tags: ["Secret"]
  9549    /secrets/{id}:
  9550      get:
  9551        summary: "Inspect a secret"
  9552        operationId: "SecretInspect"
  9553        produces:
  9554          - "application/json"
  9555        responses:
  9556          200:
  9557            description: "no error"
  9558            schema:
  9559              $ref: "#/definitions/Secret"
  9560            examples:
  9561              application/json:
  9562                ID: "ktnbjxoalbkvbvedmg1urrz8h"
  9563                Version:
  9564                  Index: 11
  9565                CreatedAt: "2016-11-05T01:20:17.327670065Z"
  9566                UpdatedAt: "2016-11-05T01:20:17.327670065Z"
  9567                Spec:
  9568                  Name: "app-dev.crt"
  9569                  Labels:
  9570                    foo: "bar"
  9571                  Driver:
  9572                    Name: "secret-bucket"
  9573                    Options:
  9574                      OptionA: "value for driver option A"
  9575                      OptionB: "value for driver option B"
  9576  
  9577          404:
  9578            description: "secret not found"
  9579            schema:
  9580              $ref: "#/definitions/ErrorResponse"
  9581          500:
  9582            description: "server error"
  9583            schema:
  9584              $ref: "#/definitions/ErrorResponse"
  9585          503:
  9586            description: "node is not part of a swarm"
  9587            schema:
  9588              $ref: "#/definitions/ErrorResponse"
  9589        parameters:
  9590          - name: "id"
  9591            in: "path"
  9592            required: true
  9593            type: "string"
  9594            description: "ID of the secret"
  9595        tags: ["Secret"]
  9596      delete:
  9597        summary: "Delete a secret"
  9598        operationId: "SecretDelete"
  9599        produces:
  9600          - "application/json"
  9601        responses:
  9602          204:
  9603            description: "no error"
  9604          404:
  9605            description: "secret not found"
  9606            schema:
  9607              $ref: "#/definitions/ErrorResponse"
  9608          500:
  9609            description: "server error"
  9610            schema:
  9611              $ref: "#/definitions/ErrorResponse"
  9612          503:
  9613            description: "node is not part of a swarm"
  9614            schema:
  9615              $ref: "#/definitions/ErrorResponse"
  9616        parameters:
  9617          - name: "id"
  9618            in: "path"
  9619            required: true
  9620            type: "string"
  9621            description: "ID of the secret"
  9622        tags: ["Secret"]
  9623    /secrets/{id}/update:
  9624      post:
  9625        summary: "Update a Secret"
  9626        operationId: "SecretUpdate"
  9627        responses:
  9628          200:
  9629            description: "no error"
  9630          400:
  9631            description: "bad parameter"
  9632            schema:
  9633              $ref: "#/definitions/ErrorResponse"
  9634          404:
  9635            description: "no such secret"
  9636            schema:
  9637              $ref: "#/definitions/ErrorResponse"
  9638          500:
  9639            description: "server error"
  9640            schema:
  9641              $ref: "#/definitions/ErrorResponse"
  9642          503:
  9643            description: "node is not part of a swarm"
  9644            schema:
  9645              $ref: "#/definitions/ErrorResponse"
  9646        parameters:
  9647          - name: "id"
  9648            in: "path"
  9649            description: "The ID or name of the secret"
  9650            type: "string"
  9651            required: true
  9652          - name: "body"
  9653            in: "body"
  9654            schema:
  9655              $ref: "#/definitions/SecretSpec"
  9656            description: "The spec of the secret to update. Currently, only the Labels field can be updated. All other fields must remain unchanged from the [SecretInspect endpoint](#operation/SecretInspect) response values."
  9657          - name: "version"
  9658            in: "query"
  9659            description: "The version number of the secret object being updated. This is required to avoid conflicting writes."
  9660            type: "integer"
  9661            format: "int64"
  9662            required: true
  9663        tags: ["Secret"]
  9664    /configs:
  9665      get:
  9666        summary: "List configs"
  9667        operationId: "ConfigList"
  9668        produces:
  9669          - "application/json"
  9670        responses:
  9671          200:
  9672            description: "no error"
  9673            schema:
  9674              type: "array"
  9675              items:
  9676                $ref: "#/definitions/Config"
  9677              example:
  9678                - ID: "ktnbjxoalbkvbvedmg1urrz8h"
  9679                  Version:
  9680                    Index: 11
  9681                  CreatedAt: "2016-11-05T01:20:17.327670065Z"
  9682                  UpdatedAt: "2016-11-05T01:20:17.327670065Z"
  9683                  Spec:
  9684                    Name: "server.conf"
  9685          500:
  9686            description: "server error"
  9687            schema:
  9688              $ref: "#/definitions/ErrorResponse"
  9689          503:
  9690            description: "node is not part of a swarm"
  9691            schema:
  9692              $ref: "#/definitions/ErrorResponse"
  9693        parameters:
  9694          - name: "filters"
  9695            in: "query"
  9696            type: "string"
  9697            description: |
  9698              A JSON encoded value of the filters (a `map[string][]string`) to process on the configs list. Available filters:
  9699  
  9700              - `id=<config id>`
  9701              - `label=<key> or label=<key>=value`
  9702              - `name=<config name>`
  9703              - `names=<config name>`
  9704        tags: ["Config"]
  9705    /configs/create:
  9706      post:
  9707        summary: "Create a config"
  9708        operationId: "ConfigCreate"
  9709        consumes:
  9710          - "application/json"
  9711        produces:
  9712          - "application/json"
  9713        responses:
  9714          201:
  9715            description: "no error"
  9716            schema:
  9717              type: "object"
  9718              properties:
  9719                ID:
  9720                  description: "The ID of the created config."
  9721                  type: "string"
  9722              example:
  9723                ID: "ktnbjxoalbkvbvedmg1urrz8h"
  9724          409:
  9725            description: "name conflicts with an existing object"
  9726            schema:
  9727              $ref: "#/definitions/ErrorResponse"
  9728          500:
  9729            description: "server error"
  9730            schema:
  9731              $ref: "#/definitions/ErrorResponse"
  9732          503:
  9733            description: "node is not part of a swarm"
  9734            schema:
  9735              $ref: "#/definitions/ErrorResponse"
  9736        parameters:
  9737          - name: "body"
  9738            in: "body"
  9739            schema:
  9740              allOf:
  9741                - $ref: "#/definitions/ConfigSpec"
  9742                - type: "object"
  9743                  example:
  9744                    Name: "server.conf"
  9745                    Labels:
  9746                      foo: "bar"
  9747                    Data: "VEhJUyBJUyBOT1QgQSBSRUFMIENFUlRJRklDQVRFCg=="
  9748        tags: ["Config"]
  9749    /configs/{id}:
  9750      get:
  9751        summary: "Inspect a config"
  9752        operationId: "ConfigInspect"
  9753        produces:
  9754          - "application/json"
  9755        responses:
  9756          200:
  9757            description: "no error"
  9758            schema:
  9759              $ref: "#/definitions/Config"
  9760            examples:
  9761              application/json:
  9762                ID: "ktnbjxoalbkvbvedmg1urrz8h"
  9763                Version:
  9764                  Index: 11
  9765                CreatedAt: "2016-11-05T01:20:17.327670065Z"
  9766                UpdatedAt: "2016-11-05T01:20:17.327670065Z"
  9767                Spec:
  9768                  Name: "app-dev.crt"
  9769          404:
  9770            description: "config not found"
  9771            schema:
  9772              $ref: "#/definitions/ErrorResponse"
  9773          500:
  9774            description: "server error"
  9775            schema:
  9776              $ref: "#/definitions/ErrorResponse"
  9777          503:
  9778            description: "node is not part of a swarm"
  9779            schema:
  9780              $ref: "#/definitions/ErrorResponse"
  9781        parameters:
  9782          - name: "id"
  9783            in: "path"
  9784            required: true
  9785            type: "string"
  9786            description: "ID of the config"
  9787        tags: ["Config"]
  9788      delete:
  9789        summary: "Delete a config"
  9790        operationId: "ConfigDelete"
  9791        produces:
  9792          - "application/json"
  9793        responses:
  9794          204:
  9795            description: "no error"
  9796          404:
  9797            description: "config not found"
  9798            schema:
  9799              $ref: "#/definitions/ErrorResponse"
  9800          500:
  9801            description: "server error"
  9802            schema:
  9803              $ref: "#/definitions/ErrorResponse"
  9804          503:
  9805            description: "node is not part of a swarm"
  9806            schema:
  9807              $ref: "#/definitions/ErrorResponse"
  9808        parameters:
  9809          - name: "id"
  9810            in: "path"
  9811            required: true
  9812            type: "string"
  9813            description: "ID of the config"
  9814        tags: ["Config"]
  9815    /configs/{id}/update:
  9816      post:
  9817        summary: "Update a Config"
  9818        operationId: "ConfigUpdate"
  9819        responses:
  9820          200:
  9821            description: "no error"
  9822          400:
  9823            description: "bad parameter"
  9824            schema:
  9825              $ref: "#/definitions/ErrorResponse"
  9826          404:
  9827            description: "no such config"
  9828            schema:
  9829              $ref: "#/definitions/ErrorResponse"
  9830          500:
  9831            description: "server error"
  9832            schema:
  9833              $ref: "#/definitions/ErrorResponse"
  9834          503:
  9835            description: "node is not part of a swarm"
  9836            schema:
  9837              $ref: "#/definitions/ErrorResponse"
  9838        parameters:
  9839          - name: "id"
  9840            in: "path"
  9841            description: "The ID or name of the config"
  9842            type: "string"
  9843            required: true
  9844          - name: "body"
  9845            in: "body"
  9846            schema:
  9847              $ref: "#/definitions/ConfigSpec"
  9848            description: "The spec of the config to update. Currently, only the Labels field can be updated. All other fields must remain unchanged from the [ConfigInspect endpoint](#operation/ConfigInspect) response values."
  9849          - name: "version"
  9850            in: "query"
  9851            description: "The version number of the config object being updated. This is required to avoid conflicting writes."
  9852            type: "integer"
  9853            format: "int64"
  9854            required: true
  9855        tags: ["Config"]
  9856    /distribution/{name}/json:
  9857      get:
  9858        summary: "Get image information from the registry"
  9859        description: "Return image digest and platform information by contacting the registry."
  9860        operationId: "DistributionInspect"
  9861        produces:
  9862          - "application/json"
  9863        responses:
  9864          200:
  9865            description: "descriptor and platform information"
  9866            schema:
  9867              type: "object"
  9868              x-go-name: DistributionInspect
  9869              required: [Descriptor, Platforms]
  9870              properties:
  9871                Descriptor:
  9872                  type: "object"
  9873                  description: "A descriptor struct containing digest, media type, and size"
  9874                  properties:
  9875                    MediaType:
  9876                      type: "string"
  9877                    Size:
  9878                      type: "integer"
  9879                      format: "int64"
  9880                    Digest:
  9881                      type: "string"
  9882                    URLs:
  9883                      type: "array"
  9884                      items:
  9885                        type: "string"
  9886                Platforms:
  9887                  type: "array"
  9888                  description: "An array containing all platforms supported by the image"
  9889                  items:
  9890                    type: "object"
  9891                    properties:
  9892                      Architecture:
  9893                        type: "string"
  9894                      OS:
  9895                        type: "string"
  9896                      OSVersion:
  9897                        type: "string"
  9898                      OSFeatures:
  9899                        type: "array"
  9900                        items:
  9901                          type: "string"
  9902                      Variant:
  9903                        type: "string"
  9904                      Features:
  9905                        type: "array"
  9906                        items:
  9907                          type: "string"
  9908            examples:
  9909              application/json:
  9910                Descriptor:
  9911                  MediaType: "application/vnd.docker.distribution.manifest.v2+json"
  9912                  Digest: "sha256:c0537ff6a5218ef531ece93d4984efc99bbf3f7497c0a7726c88e2bb7584dc96"
  9913                  Size: 3987495
  9914                  URLs:
  9915                    - ""
  9916                Platforms:
  9917                  - Architecture: "amd64"
  9918                    OS: "linux"
  9919                    OSVersion: ""
  9920                    OSFeatures:
  9921                      - ""
  9922                    Variant: ""
  9923                    Features:
  9924                      - ""
  9925          401:
  9926            description: "Failed authentication or no image found"
  9927            schema:
  9928              $ref: "#/definitions/ErrorResponse"
  9929            examples:
  9930              application/json:
  9931                message: "No such image: someimage (tag: latest)"
  9932          500:
  9933            description: "Server error"
  9934            schema:
  9935              $ref: "#/definitions/ErrorResponse"
  9936        parameters:
  9937          - name: "name"
  9938            in: "path"
  9939            description: "Image name or id"
  9940            type: "string"
  9941            required: true
  9942        tags: ["Distribution"]
  9943    /session:
  9944      post:
  9945        summary: "Initialize interactive session"
  9946        description: |
  9947          Start a new interactive session with a server. Session allows server to call back to the client for advanced capabilities.
  9948  
  9949          > **Note**: This endpoint is *experimental* and only available if the daemon is started with experimental
  9950          > features enabled. The specifications for this endpoint may still change in a future version of the API.
  9951  
  9952          ### Hijacking
  9953  
  9954          This endpoint hijacks the HTTP connection to HTTP2 transport that allows the client to expose gPRC services on that connection.
  9955  
  9956          For example, the client sends this request to upgrade the connection:
  9957  
  9958          ```
  9959          POST /session HTTP/1.1
  9960          Upgrade: h2c
  9961          Connection: Upgrade
  9962          ```
  9963  
  9964          The Docker daemon will respond with a `101 UPGRADED` response follow with the raw stream:
  9965  
  9966          ```
  9967          HTTP/1.1 101 UPGRADED
  9968          Connection: Upgrade
  9969          Upgrade: h2c
  9970          ```
  9971        operationId: "Session"
  9972        produces:
  9973          - "application/vnd.docker.raw-stream"
  9974        responses:
  9975          101:
  9976            description: "no error, hijacking successful"
  9977          400:
  9978            description: "bad parameter"
  9979            schema:
  9980              $ref: "#/definitions/ErrorResponse"
  9981          500:
  9982            description: "server error"
  9983            schema:
  9984              $ref: "#/definitions/ErrorResponse"
  9985        tags: ["Session (experimental)"]