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