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