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