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