• CLI

sdk
  1. Help Center
  2. CLI
  3. Developer Guide
  4. Mapping Between API and SDK
  5. Go
  6. ECS

ECS

Interface

Method

API

Servers

Create(client *gophercloud.ServiceClient, opts CreateOptsBuilder)

POST /v2/{tenant_id}/servers

List(client *gophercloud.ServiceClient, opts ListOptsBuilder)

GET /v2/{tenant_id}/servers/detail

Get(client *gophercloud.ServiceClient, id string)

GET /v2/{tenant_id}/servers/{server_id}

Update(client *gophercloud.ServiceClient, id string, opts UpdateOptsBuilder)

PUT /v2/{tenant_id}/servers/{server_id}

Delete(client *gophercloud.ServiceClient, id string)

DELETE /v2/{tenant_id}/servers/{server_id}

Rebuild(client *gophercloud.ServiceClient, id string, opts RebuildOptsBuilder)

POST /v2/{tenant_id}/servers/{server_id}/action

Resize(client *gophercloud.ServiceClient, id string, opts ResizeOptsBuilder)

POST /v2/{tenant_id}/servers/{server_id}/action

ConfirmResize(client *gophercloud.ServiceClient, id string)

POST /v2/{tenant_id}/servers/{server_id}/action

RevertResize(client *gophercloud.ServiceClient, id string)

POST /v2/{tenant_id}/servers/{server_id}/action

Start(client *gophercloud.ServiceClient, id string)

POST /v2/{tenant_id}/servers/{server_id}/action

Stop(client *gophercloud.ServiceClient, id string)

POST /v2/{tenant_id}/servers/{server_id}/action

Create(client *gophercloud.ServiceClient, opts servers.CreateOptsBuilder)

POST /v2/{tenant_id}/os-volumes_boot

Reboot(client *gophercloud.ServiceClient, id string, opts RebootOptsBuilder)

POST /v2/{tenant_id}/servers/{server_id}/action

ResetMetadata(client *gophercloud.ServiceClient, id string, opts ResetMetadataOptsBuilder)

PUT /v2/{tenant_id}/servers/{server_id}/metadata

Metadata(client *gophercloud.ServiceClient, id string)

GET/v2/{tenant_id}/servers/{server_id}/metadata

UpdateMetadata(client *gophercloud.ServiceClient, id string, opts UpdateMetadataOptsBuilder)

POST /v2/{tenant_id}/servers/{server_id}/metadata

Metadatum(client *gophercloud.ServiceClient, id, key string)

GET /v2/{tenant_id}/servers/{server_id}/metadata/{key}

DeleteMetadatum(client *gophercloud.ServiceClient, id, key string)

DELETE /v2/{tenant_id}/servers/{server_id}/metadata/{key}

List(client *gophercloud.ServiceClient, serverID string)

GET /v2/{tenant_id}/servers/{server_id}/os-interface

Flavors

ListDetail(client *gophercloud.ServiceClient, opts ListOptsBuilder)

GET /v2/{tenant_id}/flavors/detail

Get(client *gophercloud.ServiceClient, id string)

GET /v2/{tenant_id}/flavors/{flavor_id}

Images

ListDetail(client *gophercloud.ServiceClient, opts ListOptsBuilder)

GET /v2/{tenant_id}/images/detail

Delete(client *gophercloud.ServiceClient, id string)

DELETE /v2/{tenant_id}/images/{image_id}

Get(client *gophercloud.ServiceClient, id string)

GET /v2/{tenant_id}/images/{image_id}

Key Pairs

Create(client *gophercloud.ServiceClient, opts CreateOptsBuilder)

POST /v2/{tenant_id}/os-keypairs

Get(client *gophercloud.ServiceClient, name string)

GET /v2/{tenant_id}/os-keypairs/{keypair_name}

Delete(client *gophercloud.ServiceClient, name string)

DELETE /v2/{tenant_id}/os-keypairs/{keypair_name}

List(client *gophercloud.ServiceClient)

GET /v2/{tenant_id}/os-keypairs

Volumeattach

List(client *gophercloud.ServiceClient, serverID string)

GET /v2/{tenant_id}/servers/{server_id}/os-volume_attachments

Create(client *gophercloud.ServiceClient, serverID string, opts CreateOptsBuilder)

POST /v2/{tenant_id}/servers/{server_id}/os-volume_attachments

Get(client *gophercloud.ServiceClient, serverID, attachmentID string)

GET /v2/{tenant_id}/servers/{server_id}/os-volume_attachments/{volume_id}

Delete(client *gophercloud.ServiceClient, serverID, attachmentID string)

DELETE /v2/{tenant_id}/servers/{server_id}/os-volume_attachments/{volume_id}