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