{
  "openapi": "3.0.0",
  "info": {
    "description": "## Introduction\n\nThe resource controller is the next-generation IBM Cloud® platform provisioning layer that manages the lifecycle of IBM Cloud resources in a customer account. A resource is an instance of a service like Cloudant, a Cloud Foundry application, a virtual machine, a container, a software image, or a data set.\n\nThe resource controller provides APIs to help you manage the following elements of your resource lifecycle:\n* Catalog management\n* Provisioning (creating an instance)\n* Updating a resource instance\n* Resource keys\n* De-provisioning (deleting an instance)\n* Dashboard SSO\n\nResources are provisioned globally in an account scope. The resource controller supports both synchronous and asynchronous provisioning of resources.\n\nResources are created by the resource controller within [resource groups](https://console.cloud.ibm.com/docs/overview/resource-groups.html#whatis). A resource group belongs to an account. All IBM Cloud resources must be provisioned within a resource group. If an account is suspended, the corresponding resource group is suspended as well, and all resources within the resource group are suspended.\n\nInstalling the Java SDK\n\nMaven\n\n```xml\n<dependency>\n\t<groupId>com.ibm.cloud</groupId>\n\t<artifactId>resource-controller</artifactId>\n\t<version>{version}</version>\n</dependency>\n```\n\nGradle\n\n```bash\n'com.ibm.cloud:resource-controller:{version}'\n```\n\nReplace `{version}` in these examples with the release version.\n\nView on GitHub\n\n[https://github.com/IBM/platform-services-java-sdk](https://github.com/IBM/platform-services-java-sdk)\n\nInstalling the Go SDK\n\nGo modules (recommended): Add the following import in your code, and then run `go build` or `go mod tidy`\n\n```go\nimport (\n\t\"github.com/IBM/platform-services-go-sdk/resourcecontrollerv2\"\n)\n```\n\nGo get\n\n```bash\ngo get -u github.com/IBM/platform-services-go-sdk/resourcecontrollerv2\n```\n\nView on GitHub\n\n[https://github.com/IBM/platform-services-go-sdk](https://github.com/IBM/platform-services-go-sdk)\n\nInstallation\n\n```bash\nnpm install @ibm-cloud/platform-services\n```\n\nFor more installation options, view this project in GitHub.\nhttps://github.com/IBM/platform-services-node-sdk\n\nInstallation\n\n```bash\npip install --upgrade \"ibm-platform-services\"\n```\n\nFor more installation options, view this project in GitHub.\nhttps://github.com/IBM/platform-services-python-sdk\n\n### Resource instances\n\nThe resource controller can provision or create an instance. Provisioning reserves a resource on a service, and the reserved resource is a service instance. A resource instance can vary by service. Examples include a single database on a multi-tenant server, a dedicated cluster, or an account on a web application.\n\nAPI endpoint\n\n```bash\nhttps://resource-controller.cloud.ibm.com\n```\n\nAPI endpoint\n\n```bash\nhttps://resource-controller.cloud.ibm.com\n```\n\nAPI endpoint\n\n```bash\nhttps://resource-controller.cloud.ibm.com\n```\n\nAPI endpoint\n\n```bash\nhttps://resource-controller.cloud.ibm.com\n```\n\nAPI endpoint\n\n```bash\nhttps://resource-controller.cloud.ibm.com\n```\n\n### Using the SDK\n\nWith the Java SDK, you can build a service client for the Resource Controller by implementing the `ResourceController` class within the `com.ibm.cloud.platform_services.resource_controller.v2` package. To construct the client, you can set your options programmatically, or you can define external configuration properties to be used by your application.\n\nThe examples that are provided on this page demonstrate how to build a service client by using these two options. For more information and detailed examples, check out the [IBM Cloud SDK Common project on GitHub](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md).\n\nWith the Go SDK, you can build a service client for the Resource Controller by implementing the `ResourceControllerV2` class within the `resourcecontrollerv2` package. To construct the client, you can set your options programmatically, or you can define external configuration properties to be used by your application.\n\nThe examples that are provided on this page demonstrate how to build a service client by using these two options. For more information and detailed examples, check out the [IBM Cloud SDK Common project on GitHub](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md).\n\nWith the Node.js SDK, you can build a service client for the Resource Controller by implementing the `ResourceControllerV2` class within the `resource-controller/v2` module. To construct the client, you can set your options programmatically, or you can define external configuration properties to be used by your application.\n\nThe examples that are provided on this page demonstrate how to build a service client by using these two options. For more information and detailed examples, check out the [IBM Cloud SDK Common project on GitHub](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md).\n\nWith the Python SDK, you can build a service client for the Resource Controller by implementing the `ResourceControllerV2` class within the `ibm-platform-services` module. To construct the client, you can set your options programmatically, or you can define external configuration properties to be used by your application.\n\nThe examples that are provided on this page demonstrate how to build a service client by using these two options. For more information and detailed examples, check out the [IBM Cloud SDK Common project on GitHub](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md).\n\n## Endpoint URLs\n\nThe Resource Controller API uses the following global endpoint URL for all regions. When you call the API, add the path for each method to form the complete API endpoint for your requests.\n\n```\nhttps://resource-controller.cloud.ibm.com\n```\n\nIf you enabled service endpoints in your account, you can send API requests over the IBM Cloud private network at the following base endpoint URLs. For more information, see [Enabling VRF and service endpoints](https://cloud.ibm.com/docs/account?topic=account-vrf-service-endpoint).\n\n* Private endpoint URL for VPC infrastructure (only available in US regions): `https://private.resource-controller.cloud.ibm.com`\n* Private endpoint URLs for classic and non-US region VPC infrastructure:\n   * Dallas: `https://private.us-south.resource-controller.cloud.ibm.com`\n   * Washington DC: `https://private.us-east.resource-controller.cloud.ibm.com`\n\nExample API request\n```\ncurl -X {request_method} \"https://resource-controller.cloud.ibm.com/{method_endpoint}\"\n```\nReplace `{request_method}` and `{method_endpoint}` in this example with the values for your particular API call.\n\n## Authentication\n\nTo work with the API, you must use an IBM Cloud Identity and Access Management (IAM) access token. The token is used to determine the actions that a user or service ID has access to when they use the API.\n\nObtaining an IAM token for an authenticated user or service ID is described in the [IAM Identity Services API](https://cloud.ibm.com/apidocs/iam-identity-token-api) documentation.\n\nTo use the API, add a valid IAM token to the HTTP Authorization request header, for example, `-H 'Authorization: Bearer <TOKEN>'`.\n\nWhen you use the SDK, configure an IAM authenticator with the IAM API key. The authenticator automatically obtains the IAM access token for the API key and includes it with each request. You can construct an authenticator in either of two ways:\n- Programmatically by constructing an IAM authenticator instance and supplying your IAM API key\n- By defining the API key in external configuration properties and then using the SDK authenticator factory to construct an IAM authenticator that uses the configured IAM API key\n\nIn this example of using external configuration properties, an IAM authenticator instance is created with the configured API key, and then the service client is constructed with this authenticator instance and the configured service URL.\n\nFor more information, see the Authentication section of the [IBM Cloud SDK Common](https://github.com/IBM/ibm-cloud-sdk-common/blob/main/README.md) documentation.\n\nFor more information, see [IAM authentication with the SDK](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md#authentication).\n\nFor more information, see [IAM authentication with the SDK](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md#authentication).\n\nFor more information, see [IAM authentication with the SDK](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md#authentication).\n\nFor more information, see [IAM authentication with the SDK](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md#authentication).\n\nTo retrieve your access token:\n\n```bash\ncurl -X POST\nhttps://iam.cloud.ibm.com/identity/token\n  -H \"Content-Type: application/x-www-form-urlencoded\"\n  -H \"Accept: application/json\"\n  -d \"grant_type=urn%3Aibm%3Aparams%3Aoauth%3Agrant-type%3Aapikey&apikey=<API_KEY>\"\n```\n\nReplace `<API_KEY>` with your service credentials. Then, use the full `IAM token` value that is prefixed by the _Bearer_ token type to authenticate your API requests.\n\nTo retrieve your instance ID:\n\n```bash\nibmcloud resource service-instance <instance_name> --id\n```\n\nReplace `<instance_name>` with the `name` that you assigned to your service instance.\n\nSetting client options through external configuration\n\nExample environment variables, where `<API_KEY>` is your IAM API key\n```sh\nexport RESOURCE_CONTROLLER_APIKEY=<API_KEY>\n```\n\nExample of constructing the service client\n```java\nimport com.ibm.cloud.platform_services.resource_controller.v2.ResourceController;\n...\nResourceController resourceControllerService = ResourceController.newInstance();\n```\n\nSetting client options through external configuration\n\nExample environment variables, where `<API_KEY>` is your IAM API key\n```sh\nexport RESOURCE_CONTROLLER_APIKEY=<API_KEY>\n```\n\nExample of constructing the service client\n```go\nimport {\n    \"github.com/IBM/platform-services-go-sdk/resourcecontrollerv2\"\n}\n...\nresourceControllerServiceOptions := &resourcecontrollerv2.ResourceControllerV2Options{}\nresourceControllerService, err := resourcecontrollerv2.NewResourceControllerV2UsingExternalConfig(resourceControllerServiceOptions)\n```\n\nSetting client options through external configuration\n\nExample environment variables, where `<API_KEY>` is your IAM API key\n```sh\nexport RESOURCE_CONTROLLER_APIKEY=<API_KEY>\n```\n\nExample of constructing the service client\n```python\nfrom ibm_platform_services import ResourceControllerV2\n...\nresource_controller_service = ResourceControllerV2.new_instance()\n```\n\nSetting client options through external configuration\n\nExample environment variables, where `<API_KEY>` is your IAM API key\n```sh\nexport RESOURCE_CONTROLLER_APIKEY=<API_KEY>\n```\n\nExample of constructing the service client\n```javascript\nconst ResourceControllerV2 = require('ibm-platform-services/resource-controller/v2');\n...\nconst resourceControllerService = ResourceControllerV2.newInstance({});\n```\n\n## Error handling\n\nThis API uses standard HTTP response codes to indicate whether a method completed successfully. A `200` response indicates success. A `400` type response indicates a failure, and a `500` type response indicates an internal system error.\n\nAdditionally, each response includes a `Transaction-Id` header that can be referenced when you contact [IBM Cloud support](https://www.ibm.com/cloud/support).\n\n| HTTP Error Code | Description           | Recovery |\n|-----------------|-----------------------|----------|\n| `200`           | Success               | The request was successful. |\n| `400`           | Bad Request           | The input parameters in the request body are either incomplete or in the wrong format. Be sure to include all required parameters in your request. |\n| `401`           | Unauthorized          | You are not authorized to make this request. Log in to IBM Cloud and try again. If this error persists, contact the account owner to check your permissions.\t|\n| `403`           | Forbidden             | The supplied authentication is not authorized to access '{namespace}'. |\n| `404`           | Not Found             | The requested resource could not be found. |\n| `409`           | Conflict              | The entity is already in the requested state. |\n| `410`           | Gone                  | The resource is valid but was removed in a previous call. |\n| `500`           | Internal Server Error | *Offering_name* is unavailable. Your request could not be processed. Wait a few minutes and try again. |\n\n## Auditing\n\nYou can monitor API activity within your account by using the IBM Cloud Logs service. Whenever an API method is called, an event is generated that you can then track and audit from within IBM Cloud Logs. The specific event type is listed for each individual method.\n\nFor more information about how to track Account and Billing activity, see [Activity tracking events for account management](https://cloud.ibm.com/docs/account?topic=account-at_events_am).\n\n## Pagination\n\nSome API requests might return a large number of results. To avoid performance issues, these results are returned one page at a time, with a limited number of results on each page. GET requests for the following resources use pagination:\n\n   * /v2/resource_instances\n   * /v2/resource_keys\n\nThe default page and max size is 100 objects. To use a different page size, use the `limit` query parameter.\n\nFor any request that uses pagination, the response includes a `next_url` object that specifies pagination information. `next_url` is the URL for requesting the next page of results. The `next_url` property is null if there are no more results, and retains the same `limit` parameter that is used for the initial request.\n\n## Rate limiting\n\nRate limits for API requests are enforced on a per-caller basis. If the number of requests for a particular method and endpoint reaches the request limit within the specified time window, no further requests are accepted until the timer expires. After the timer expires, a new time window begins with the next accepted request.\n\nThe response to each HTTP request includes headers you can use to determine whether you are close to the rate limit:\n\n   * X-RateLimit-Reset: the time the current timer expires (in UNIX epoch time)\n   * X-RateLimit-Remaining: the number of remaining requests in the current time window\n   * X-RateLimit-Limit: the total number of requests allowed within the time window\n\nAn HTTP status code of 429 indicates that the rate limit was exceeded.\n\nThe number of allowed requests, and the length of the time window, vary by method and endpoint. The reference information for each endpoint specifies the rate limit that applies.\n\n## Related APIs\n\nWhen you work with the resource controller endpoints, it might be helpful to be aware of the IBM Cloud OSB APIs used to create your service broker.\n\n* [IBM Cloud Open Service Broker](https://cloud.ibm.com/apidocs/resource-controller/ibm-cloud-osb-api)\n* [IBM Cloud Resource Manager](https://cloud.ibm.com/apidocs/resource-controller/resource-manager)",
    "version": "2.0",
    "title": "Resource Controller",
    "x-alternate-name": "resource_controller",
    "contact": {
      "name": "IBM"
    },
    "x-codegen-config": {
      "java": {
        "apiPackage": "com.ibm.cloud.platform_services"
      },
      "go": {
        "apiPackage": "github.com/IBM/platform-services-go-sdk",
        "improvedNameFormattingV2": true
      },
      "python": {
        "apiPackage": "ibm_platform_services"
      }
    },
    "x-github": "https://github.ibm.com/cloud-api-docs/resource-controller",
    "x-github-issues": "https://github.ibm.com/cloud-api-docs/resource-controller/issues/new",
    "x-last-updated": "2025-01-21"
  },
  "tags": [
    {
      "description": "Resource Instances",
      "name": "Resource Instances"
    },
    {
      "description": "Resource Keys",
      "name": "Resource Keys"
    },
    {
      "description": "Resource Reclamations",
      "name": "Resource Reclamations"
    }
  ],
  "servers": [
    {
      "url": "https://resource-controller.cloud.ibm.com",
      "description": "Production"
    }
  ],
  "security": [
    {
      "IAM": []
    }
  ],
  "paths": {
    "/v2/resource_instances": {
      "get": {
        "tags": [
          "Resource Instances"
        ],
        "summary": "Get a list of all resource instances",
        "description": "View a list of all available resource instances. Resources is a broad term that could mean anything from a service instance to a virtual machine associated with the customer account.",
        "operationId": "list_resource_instances",
        "parameters": [
          {
            "name": "guid",
            "description": "The GUID of the instance.",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "name",
            "description": "The human-readable name of the instance.",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "resource_group_id",
            "in": "query",
            "description": "The ID of the resource group.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "resource_id",
            "in": "query",
            "description": "The unique ID of the offering. This value is provided by and stored in the global catalog.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "resource_plan_id",
            "in": "query",
            "description": "The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "type",
            "in": "query",
            "description": "The type of the instance, for example, `service_instance`.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "sub_type",
            "in": "query",
            "description": "The sub-type of instance, for example, `kms`.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "subscription_id",
            "in": "query",
            "description": "The ID of the subscription.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Limit on how many items should be returned. The number of items returned may be less than the specified limit if the caller lacks sufficient access to retrieve certain resource instances.",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 100,
              "default": 100
            }
          },
          {
            "name": "start",
            "in": "query",
            "description": "An optional token that indicates the beginning of the page of results to be returned. Any additional query parameters are ignored if a page token is present. If omitted, the first page of results is returned. This value is obtained from the 'start' query parameter in the 'next_url' field of the operation response.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "state",
            "in": "query",
            "description": "The state of the instance. If not specified, instances in state `active`, `inactive`, `failed`, `provisioning` and `pre_provisioning` are returned.",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "active",
                "inactive",
                "failed",
                "pending_reclamation",
                "provisioning",
                "pre_provisioning",
                "removed"
              ]
            }
          },
          {
            "name": "updated_from",
            "in": "query",
            "description": "Start date inclusive filter.",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "2021-01-01"
          },
          {
            "name": "updated_to",
            "in": "query",
            "description": "End date inclusive filter.",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "2021-01-01"
          },
          {
            "name": "sort",
            "in": "query",
            "description": "Optional sort property, valid values are `name`, `created_at` and `updated_at`. If specified, the items are sorted by the value of this property.",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "name",
                "created_at",
                "updated_at"
              ],
              "default": "name"
            }
          },
          {
            "name": "order",
            "in": "query",
            "description": "Optional sort order, valid values are `asc` and `desc`.",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "asc",
                "desc"
              ],
              "default": "asc"
            }
          }
        ],
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X GET \\\n  https://resource-controller.cloud.ibm.com/v2/resource_instances \\\n  -H \"Authorization: Bearer <IAM token>\""
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "listResourceInstancesOptions := &resourcecontrollerv2.ListResourceInstancesOptions{\n",
                      "  Name: &resourceInstanceName,\n",
                      "}\n",
                      "\n",
                      "pager, err := resourceControllerService.NewResourceInstancesPager(listResourceInstancesOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "\n",
                      "var allResults []resourcecontrollerv2.ResourceInstance\n",
                      "for pager.HasNext() {\n",
                      "  nextPage, err := pager.GetNext()\n",
                      "  if err != nil {\n",
                      "    panic(err)\n",
                      "  }\n",
                      "  allResults = append(allResults, nextPage...)\n",
                      "}\n",
                      "b, _ := json.MarshalIndent(allResults, \"\", \"  \")\n",
                      "fmt.Println(string(b))"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "ListResourceInstancesOptions listResourceInstancesOptions = new ListResourceInstancesOptions.Builder()\n",
                      "  .name(resourceInstanceName)\n",
                      "  .build();\n",
                      "\n",
                      "ResourceInstancesPager pager =\n",
                      "    new ResourceInstancesPager(resourceControllerService, listResourceInstancesOptions);\n",
                      "List<ResourceInstance> allResults = new ArrayList<>();\n",
                      "while (pager.hasNext()) {\n",
                      "  List<ResourceInstance> nextPage = pager.getNext();\n",
                      "  allResults.addAll(nextPage);\n",
                      "}\n",
                      "\n",
                      "System.out.println(GsonSingleton.getGson().toJson(allResults));"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  name: resourceInstanceName,\n",
                      "};\n",
                      "\n",
                      "const allResults = [];\n",
                      "try {\n",
                      "  const pager = new ResourceControllerV2.ResourceInstancesPager(\n",
                      "    resourceControllerService, params);\n",
                      "  while (pager.hasNext()) {\n",
                      "    const nextPage = await pager.getNext();\n",
                      "    expect(nextPage).not.toBeNull();\n",
                      "    allResults.push(...nextPage);\n",
                      "  }\n",
                      "  console.log(JSON.stringify(allResults, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "all_results = []\n",
                      "pager = ResourceInstancesPager(\n",
                      "  client=resource_controller_service,\n",
                      "  name=resource_instance_name,\n",
                      ")\n",
                      "while pager.has_next():\n",
                      "  next_page = pager.get_next()\n",
                      "  assert next_page is not None\n",
                      "  all_results.extend(next_page)\n",
                      "\n",
                      "print(json.dumps(all_results, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.instance.retrieve"
            }
          ]
        },
        "responses": {
          "200": {
            "description": "The list of resource instances was successfully retrieved.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceInstancesList"
                },
                "example": {
                  "rows_count": 1,
                  "next_url": "/v2/resource_instances?start=bmV4dF9kb2NpZD1nMUFBQUFGVGVKekxZV0JnWU1sZ1RtSFFTa2xLemk5S2RVaEpNdFZMeXRWTlR0Wk5TVTNKVEU0c1NVMHhNckRVUzg3SkwwMUp6Q3ZSeTBzdHlRSHFZVW9TQUpKSjh2X19fODhDODkyY1N0XzlxWGc5Z1NGeFJ4YXFlZWJFbWFjQU1rOGZ5Ynl5eE5Pdml6NHdKREV3YU5pUVoyUUF5TWg0WkNjLU43cTQ0UUxJU0QyMUxISjhuY2NDSkJrV0FDbWdxZXZoTGsxbTRGQUNHOXMtSnlzTEFONl9iU2cmbGltaXQ9NSZhY2NvdW50X2lkPTQzMjkwNzNkMTZkMmYzNjYzZjc0YmZhOTU1MjU5MTM5",
                  "resources": [
                    {
                      "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                      "guid": "8d7af921-b136-4078-9666-081bd8470d94",
                      "url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94",
                      "created_at": "2018-04-19T00:18:53.302077457Z",
                      "updated_at": "2018-04-19T00:18:53.302077457Z",
                      "deleted_at": null,
                      "created_by": "IBMid-5500093BHN",
                      "updated_by": "IBMid-5500093BHN",
                      "deleted_by": "",
                      "scheduled_reclaim_at": null,
                      "restored_at": null,
                      "scheduled_reclaim_by": "",
                      "restored_by": "",
                      "name": "my-instance",
                      "region_id": "global",
                      "account_id": "4329073d16d2f3663f74bfa955259139",
                      "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                      "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                      "resource_group_crn": "crn:v1:bluemix:public:resource-controller::a/4329073d16d2f3663f74bfa955259139::resource-group:0be5ad401ae913d8ff665d92680664ed",
                      "target_crn": "crn:v1:bluemix:public:resource-catalog::a/9e16d1fed8aa7e1bd73e7a9d23434a5a::deployment:2fdf0c08-2d32-4f46-84b5-32e0c92fffd8%3Aglobal",
                      "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                      "allow_cleanup": true,
                      "state": "active",
                      "type": "service_instance",
                      "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                      "dashboard_url": "/objectstorage/crn%3Av1%3Abluemix%3Apublic%3Acloud-object-storage%3Aglobal%3Aa%2F4329073d16d2f3663f74bfa955259139%3A8d7af921-b136-4078-9666-081bd8470d94%3A%3A",
                      "last_operation": null,
                      "resource_keys_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/resource_keys",
                      "plan_history": [
                        {
                          "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                          "start_date": "2018-04-19T00:18:53.302077457Z"
                        }
                      ],
                      "migrated": false,
                      "controlled_by": ""
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      },
      "post": {
        "tags": [
          "Resource Instances"
        ],
        "summary": "Create (provision) a new resource instance",
        "description": "When you provision a service you get an instance of that service. An instance represents the resource with which you create, and additionally, represents a chargeable record of which billing can occur.",
        "operationId": "create_resource_instance",
        "parameters": [
          {
            "name": "Entity-Lock",
            "in": "header",
            "description": "Indicates if the resource instance is locked for further update or delete operations. It does not affect actions performed on child resources like keys. False by default.",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ResourceInstancePost"
              },
              "example": {
                "name": "ExampleResourceInstance",
                "resource_group": "13aa3ee48c3b44ddb64c05c79f7ab8ef",
                "resource_plan_id": "a10e4960-3685-11e9-b210-d663bd873d93",
                "target": "global"
              }
            }
          }
        },
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X POST \\\n  https://resource-controller.cloud.ibm.com/v2/resource_instances \\\n  -H \"Authorization: Bearer <IAM token>\" \\\n  -H 'Content-Type: application/json' \\\n    -d '{\n    \"name\": \"my-instance\",\n    \"target\": \"us-south\",\n    \"resource_group\": \"5c49eabc-f5e8-5881-a37e-2d100a33b3df\",\n    \"resource_plan_id\": \"cloudant-standard\",\n    \"tags\": [\n      \"my-tag\"\n    ]\n  }'"
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "createResourceInstanceOptions := resourceControllerService.NewCreateResourceInstanceOptions(\n",
                      "  resourceInstanceName,\n",
                      "  targetRegion,\n",
                      "  resourceGroup,\n",
                      "  resourcePlanID,\n",
                      ")\n",
                      "\n",
                      "resourceInstance, response, err := resourceControllerService.CreateResourceInstance(createResourceInstanceOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "\n",
                      "b, _ := json.MarshalIndent(resourceInstance, \"\", \"  \")\n",
                      "fmt.Println(string(b))"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "CreateResourceInstanceOptions createResourceInstanceOptions = new CreateResourceInstanceOptions.Builder()\n",
                      "  .name(resourceInstanceName)\n",
                      "  .target(targetRegion)\n",
                      "  .resourceGroup(resourceGroup)\n",
                      "  .resourcePlanId(resourcePlanId)\n",
                      "  .build();\n",
                      "\n",
                      "Response<ResourceInstance> response = resourceControllerService.createResourceInstance(createResourceInstanceOptions).execute();\n",
                      "ResourceInstance resourceInstance = response.getResult();\n",
                      "\n",
                      "System.out.println(resourceInstance);"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  name: resourceInstanceName,\n",
                      "  target: targetRegion,\n",
                      "  resourceGroup: resourceGroupGuid,\n",
                      "  resourcePlanId: resourcePlanId,\n",
                      "};\n",
                      "\n",
                      "try {\n",
                      "  const res = await resourceControllerService.createResourceInstance(params)\n",
                      "  instanceGuid = res.result.guid;\n",
                      "  console.log(JSON.stringify(res.result, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "resource_instance = resource_controller_service.create_resource_instance(\n",
                      "  name=resource_instance_name,\n",
                      "  target=target_region,\n",
                      "  resource_group=resource_group,\n",
                      "  resource_plan_id=resource_plan_id\n",
                      ").get_result()\n",
                      "\n",
                      "print(json.dumps(resource_instance, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.instance.create"
            }
          ]
        },
        "x-ibm-events": {
          "description": null,
          "events": [
            {
              "name": "resource-controller.instance.create"
            }
          ]
        },
        "responses": {
          "201": {
            "description": "The resource instance was provisioned.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceInstance"
                },
                "example": {
                  "id": "crn:v1:bluemix:public:cloudantnosqldb:us-south:a/d86af7367f70fba4f306d3c19c7344b2:b723751c-69c1-4e4b-a4dc-ccfccf6c20a0::",
                  "guid": "8d7af921-b136-4078-9666-081bd8470d94",
                  "url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94",
                  "created_at": "2018-04-19T00:18:53.302077457Z",
                  "updated_at": "2018-04-19T00:18:53.302077457Z",
                  "deleted_at": null,
                  "created_by": "IBMid-5500093BHN",
                  "updated_by": "IBMid-5500093BHN",
                  "deleted_by": "",
                  "scheduled_reclaim_at": null,
                  "restored_at": null,
                  "scheduled_reclaim_by": "",
                  "restored_by": "",
                  "name": "my-instance",
                  "region_id": "us-south",
                  "account_id": "4329073d16d2f3663f74bfa955259139",
                  "resource_plan_id": "cloudant-standard",
                  "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                  "resource_group_crn": "crn:v1:bluemix:public:resource-controller::a/4329073d16d2f3663f74bfa955259139::resource-group:0be5ad401ae913d8ff665d92680664ed",
                  "target_crn": "crn:v1:bluemix:public:resource-catalog::a/9e16d1fed8aa7e1bd73e7a9d23434a5a::deployment:2fdf0c08-2d32-4f46-84b5-32e0c92fffd8%3Aglobal",
                  "crn": "crn:v1:bluemix:public:cloudantnosqldb:us-south:a/d86af7367f70fba4f306d3c19c7344b2:b723751c-69c1-4e4b-a4dc-ccfccf6c20a0::",
                  "allow_cleanup": false,
                  "state": "active",
                  "type": "service_instance",
                  "resource_id": "cloudant",
                  "dashboard_url": "https://dashboard.cloudantnosqldb.cloud.ibm.com/rc/account/crn%3Av1%3Abluemix%3Apublic%3Acloudantnosqldb%3Aus-south%3Aa%2Fd86af7367f70fba4f306d3c19c7344b2%3Ab723751c-69c1-4e4b-a4dc-ccfccf6c20a0%3A%3A",
                  "last_operation": null,
                  "resource_keys_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/resource_keys",
                  "plan_history": [
                    {
                      "resource_plan_id": "cloudant-standard",
                      "start_date": "2018-04-19T00:18:53.302077457Z"
                    }
                  ],
                  "migrated": false,
                  "controlled_by": ""
                }
              }
            },
            "links": {
              "ResourceInstanceId": {
                "$ref": "#/components/links/ResourceInstanceId"
              }
            }
          },
          "202": {
            "description": "Request to provision a resource has been accepted by the broker, and provisioning is in progress. This triggers the platform to poll the service's broker for operation status. Users can call `get_resource_instance` to get the current state of the instance.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceInstance"
                },
                "example": {
                  "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "guid": "8d7af921-b136-4078-9666-081bd8470d94",
                  "url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94",
                  "created_at": "2018-04-19T00:18:53.302077457Z",
                  "updated_at": "2018-04-19T00:18:53.302077457Z",
                  "deleted_at": null,
                  "created_by": "IBMid-5500093BHN",
                  "updated_by": "IBMid-5500093BHN",
                  "deleted_by": "",
                  "scheduled_reclaim_at": null,
                  "restored_at": null,
                  "scheduled_reclaim_by": "",
                  "restored_by": "",
                  "name": "my-instance",
                  "region_id": "global",
                  "account_id": "4329073d16d2f3663f74bfa955259139",
                  "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                  "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                  "resource_group_crn": "crn:v1:bluemix:public:resource-controller::a/4329073d16d2f3663f74bfa955259139::resource-group:0be5ad401ae913d8ff665d92680664ed",
                  "target_crn": "crn:v1:bluemix:public:resource-catalog::a/9e16d1fed8aa7e1bd73e7a9d23434a5a::deployment:2fdf0c08-2d32-4f46-84b5-32e0c92fffd8%3Aglobal",
                  "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "allow_cleanup": false,
                  "state": "provisioning",
                  "type": "service_instance",
                  "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                  "dashboard_url": "/objectstorage/crn%3Av1%3Abluemix%3Apublic%3Acloud-object-storage%3Aglobal%3Aa%2F4329073d16d2f3663f74bfa955259139%3A8d7af921-b136-4078-9666-081bd8470d94%3A%3A",
                  "last_operation": {
                    "type": "create",
                    "state": "in progress",
                    "async": true,
                    "description": "Started create instance operation",
                    "cancelable": false,
                    "poll": true
                  },
                  "resource_keys_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/resource_keys",
                  "plan_history": [
                    {
                      "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                      "start_date": "2018-04-19T00:18:53.302077457Z"
                    }
                  ],
                  "migrated": false,
                  "controlled_by": ""
                }
              }
            },
            "links": {
              "ResourceInstanceId": {
                "$ref": "#/components/links/ResourceInstanceId"
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      }
    },
    "/v2/resource_instances/{id}": {
      "parameters": [
        {
          "name": "id",
          "description": "The resource instance URL-encoded CRN or GUID.",
          "in": "path",
          "required": true,
          "schema": {
            "type": "string"
          },
          "x-linkback": "#/components/links/ResourceInstanceId"
        }
      ],
      "get": {
        "tags": [
          "Resource Instances"
        ],
        "summary": "Get a resource instance",
        "description": "Retrieve a resource instance by URL-encoded CRN or GUID. Find more details on a particular instance, like when it was provisioned and who provisioned it.",
        "operationId": "get_resource_instance",
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X GET \\\n  https://resource-controller.cloud.ibm.com/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94 \\\n  -H \"Authorization: Bearer <IAM token>\" \\"
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "getResourceInstanceOptions := resourceControllerService.NewGetResourceInstanceOptions(\n",
                      "  instanceGUID,\n",
                      ")\n",
                      "\n",
                      "resourceInstance, response, err := resourceControllerService.GetResourceInstance(getResourceInstanceOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "b, _ := json.MarshalIndent(resourceInstance, \"\", \"  \")\n",
                      "fmt.Println(string(b))"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "GetResourceInstanceOptions getResourceInstanceOptions = new GetResourceInstanceOptions.Builder()\n",
                      "  .id(instanceGuid)\n",
                      "  .build();\n",
                      "\n",
                      "Response<ResourceInstance> response = resourceControllerService.getResourceInstance(getResourceInstanceOptions).execute();\n",
                      "ResourceInstance resourceInstance = response.getResult();\n",
                      "\n",
                      "System.out.println(resourceInstance);"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  id: instanceGuid,\n",
                      "};\n",
                      "\n",
                      "try {\n",
                      "  const res = await resourceControllerService.getResourceInstance(params);\n",
                      "  console.log(JSON.stringify(res.result, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "resource_instance = resource_controller_service.get_resource_instance(\n",
                      "  id=instance_guid\n",
                      ").get_result()\n",
                      "\n",
                      "print(json.dumps(resource_instance, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.instance.retrieve"
            }
          ]
        },
        "responses": {
          "200": {
            "description": "The resource instance was successfully retrieved.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceInstance"
                },
                "example": {
                  "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "guid": "8d7af921-b136-4078-9666-081bd8470d94",
                  "url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94",
                  "created_at": "2018-04-19T00:18:53.302077457Z",
                  "updated_at": "2018-04-19T00:18:53.302077457Z",
                  "deleted_at": null,
                  "created_by": "IBMid-5500093BHN",
                  "updated_by": "IBMid-5500093BHN",
                  "deleted_by": "",
                  "scheduled_reclaim_at": null,
                  "restored_at": null,
                  "scheduled_reclaim_by": "",
                  "restored_by": "",
                  "name": "my-instance",
                  "region_id": "global",
                  "account_id": "4329073d16d2f3663f74bfa955259139",
                  "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                  "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                  "resource_group_crn": "crn:v1:bluemix:public:resource-controller::a/4329073d16d2f3663f74bfa955259139::resource-group:0be5ad401ae913d8ff665d92680664ed",
                  "target_crn": "crn:v1:bluemix:public:resource-catalog::a/9e16d1fed8aa7e1bd73e7a9d23434a5a::deployment:2fdf0c08-2d32-4f46-84b5-32e0c92fffd8%3Aglobal",
                  "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "allow_cleanup": false,
                  "state": "active",
                  "type": "service_instance",
                  "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                  "dashboard_url": "/objectstorage/crn%3Av1%3Abluemix%3Apublic%3Acloud-object-storage%3Aglobal%3Aa%2F4329073d16d2f3663f74bfa955259139%3A8d7af921-b136-4078-9666-081bd8470d94%3A%3A",
                  "last_operation": null,
                  "resource_keys_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/resource_keys",
                  "plan_history": [
                    {
                      "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                      "start_date": "2018-04-19T00:18:53.302077457Z"
                    }
                  ],
                  "migrated": false,
                  "controlled_by": ""
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      },
      "delete": {
        "tags": [
          "Resource Instances"
        ],
        "summary": "Delete a resource instance",
        "description": "Delete a resource instance by URL-encoded CRN or GUID. If the resource instance has any resource keys associated with it, use the `recursive=true` parameter to delete it.",
        "operationId": "delete_resource_instance",
        "parameters": [
          {
            "name": "recursive",
            "description": "Will delete keys associated with the instance.",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false
            }
          }
        ],
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X DELETE \\\n  https://resource-controller.cloud.ibm.com/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94 \\\n  -H \"Authorization: Bearer <IAM token>\""
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "deleteResourceInstanceOptions := resourceControllerService.NewDeleteResourceInstanceOptions(\n",
                      "  instanceGUID,\n",
                      ")\n",
                      "deleteResourceInstanceOptions.SetRecursive(false)\n",
                      "\n",
                      "response, err := resourceControllerService.DeleteResourceInstance(deleteResourceInstanceOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "DeleteResourceInstanceOptions deleteResourceInstanceOptions = new DeleteResourceInstanceOptions.Builder()\n",
                      "  .id(instanceGuid)\n",
                      "  .recursive(false)\n",
                      "  .build();\n",
                      "\n",
                      "Response<Void> response = resourceControllerService.deleteResourceInstance(deleteResourceInstanceOptions).execute();"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  id: instanceGuid,\n",
                      "  recursive: false,\n",
                      "};\n",
                      "\n",
                      "try {\n",
                      "  await resourceControllerService.deleteResourceInstance(params);\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "response = resource_controller_service.delete_resource_instance(\n",
                      "  id=instance_guid,\n",
                      "  recursive=False\n",
                      ")"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.instance.delete"
            }
          ]
        },
        "x-ibm-events": {
          "description": null,
          "events": [
            {
              "name": "resource-controller.instance.delete"
            }
          ]
        },
        "responses": {
          "202": {
            "description": "Request to delete a resource has been accepted by the broker, and deletion is in progress. This triggers the platform to poll the service's broker for operation status. Users can call `get_resource_instance` to get the current state of the instance."
          },
          "204": {
            "description": "Deleted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "410": {
            "$ref": "#/components/responses/Gone"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      },
      "patch": {
        "tags": [
          "Resource Instances"
        ],
        "summary": "Update a resource instance",
        "description": "Use the resource instance URL-encoded CRN or GUID to make updates to the resource instance, like changing the name or plan.",
        "operationId": "update_resource_instance",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ResourceInstancePatch"
              },
              "example": {
                "name": "UpdatedExampleResourceInstance",
                "parameters": {
                  "exampleProperty": "exampleValue"
                }
              }
            }
          }
        },
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X PATCH \\\n  https://resource-controller.cloud.ibm.com/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94 \\\n  -H \"Authorization: Bearer <IAM token>\" \\\n  -H 'Content-Type: application/json' \\\n    -d '{\n    \"name\": \"my-instance-new-binding-1\",\n    \"resource_plan_id\": \"744bfc56-d12c-4866-88d5-dac9139e0e5d\"\n  }'"
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "parameters := map[string]interface{}{\"exampleProperty\": \"exampleValue\"}\n",
                      "updateResourceInstanceOptions := resourceControllerService.NewUpdateResourceInstanceOptions(\n",
                      "  instanceGUID,\n",
                      ")\n",
                      "updateResourceInstanceOptions = updateResourceInstanceOptions.SetName(resourceInstanceUpdateName)\n",
                      "updateResourceInstanceOptions = updateResourceInstanceOptions.SetParameters(parameters)\n",
                      "\n",
                      "resourceInstance, response, err := resourceControllerService.UpdateResourceInstance(updateResourceInstanceOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "b, _ := json.MarshalIndent(resourceInstance, \"\", \"  \")\n",
                      "fmt.Println(string(b))"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "Map<String, Object> parameters = new HashMap<String, Object>();\n",
                      "parameters.put(\"exampleProperty\", \"exampleValue\");\n",
                      "\n",
                      "UpdateResourceInstanceOptions updateResourceInstanceOptions = new UpdateResourceInstanceOptions.Builder()\n",
                      "  .id(instanceGuid)\n",
                      "  .name(resourceInstanceUpdateName)\n",
                      "  .parameters(parameters)\n",
                      "  .build();\n",
                      "\n",
                      "Response<ResourceInstance> response = resourceControllerService.updateResourceInstance(updateResourceInstanceOptions).execute();\n",
                      "ResourceInstance resourceInstance = response.getResult();\n",
                      "\n",
                      "System.out.println(resourceInstance);"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const parameters = {\n",
                      "  'exampleParameter': 'exampleValue',\n",
                      "};\n",
                      "\n",
                      "const params = {\n",
                      "  id: instanceGuid,\n",
                      "  name: resourceInstanceUpdateName,\n",
                      "  parameters: parameters,\n",
                      "};\n",
                      "\n",
                      "try {\n",
                      "  const res = await resourceControllerService.updateResourceInstance(params);\n",
                      "  console.log(JSON.stringify(res.result, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "parameters = {\n",
                      "  'exampleProperty': 'exampleValue'\n",
                      "}\n",
                      "resource_instance = resource_controller_service.update_resource_instance(\n",
                      "  id=instance_guid,\n",
                      "  name=resource_instance_update_name,\n",
                      "  parameters=parameters\n",
                      ").get_result()\n",
                      "\n",
                      "print(json.dumps(resource_instance, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.instance.update"
            }
          ]
        },
        "x-ibm-events": {
          "description": null,
          "events": [
            {
              "name": "resource-controller.instance.update"
            }
          ]
        },
        "responses": {
          "200": {
            "description": "The requested changes have been applied",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceInstance"
                },
                "example": {
                  "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "guid": "8d7af921-b136-4078-9666-081bd8470d94",
                  "url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94",
                  "created_at": "2018-04-19T00:18:53.302077457Z",
                  "updated_at": "2018-04-19T00:18:53.302077457Z",
                  "deleted_at": null,
                  "created_by": "IBMid-5500093BHN",
                  "updated_by": "IBMid-5500093BHN",
                  "deleted_by": "",
                  "scheduled_reclaim_at": null,
                  "restored_at": null,
                  "scheduled_reclaim_by": "",
                  "restored_by": "",
                  "name": "my-instance",
                  "region_id": "global",
                  "account_id": "4329073d16d2f3663f74bfa955259139",
                  "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                  "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                  "resource_group_crn": "crn:v1:bluemix:public:resource-controller::a/4329073d16d2f3663f74bfa955259139::resource-group:0be5ad401ae913d8ff665d92680664ed",
                  "target_crn": "crn:v1:bluemix:public:resource-catalog::a/9e16d1fed8aa7e1bd73e7a9d23434a5a::deployment:2fdf0c08-2d32-4f46-84b5-32e0c92fffd8%3Aglobal",
                  "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "allow_cleanup": false,
                  "state": "active",
                  "type": "service_instance",
                  "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                  "dashboard_url": "/objectstorage/crn%3Av1%3Abluemix%3Apublic%3Acloud-object-storage%3Aglobal%3Aa%2F4329073d16d2f3663f74bfa955259139%3A8d7af921-b136-4078-9666-081bd8470d94%3A%3A",
                  "last_operation": null,
                  "resource_keys_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/resource_keys",
                  "plan_history": [
                    {
                      "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                      "start_date": "2018-04-19T00:18:53.302077457Z"
                    }
                  ],
                  "migrated": false,
                  "controlled_by": ""
                }
              }
            }
          },
          "202": {
            "description": "Request to update a resource has been accepted by the broker, and update is in progress. This triggers the platform to poll the service's broker for operation status. Users can call `get_resource_instance` to get the current state of the instance.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceInstance"
                },
                "example": {
                  "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "guid": "8d7af921-b136-4078-9666-081bd8470d94",
                  "url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94",
                  "created_at": "2018-04-19T00:18:53.302077457Z",
                  "updated_at": "2018-04-19T00:18:53.302077457Z",
                  "deleted_at": null,
                  "created_by": "IBMid-5500093BHN",
                  "updated_by": "IBMid-5500093BHN",
                  "deleted_by": "",
                  "scheduled_reclaim_at": null,
                  "restored_at": null,
                  "scheduled_reclaim_by": "",
                  "restored_by": "",
                  "name": "my-instance",
                  "region_id": "global",
                  "account_id": "4329073d16d2f3663f74bfa955259139",
                  "resource_plan_id": "744bfc56-d12c-4866-88d5-dac9139e0e5d",
                  "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                  "resource_group_crn": "crn:v1:bluemix:public:resource-controller::a/4329073d16d2f3663f74bfa955259139::resource-group:0be5ad401ae913d8ff665d92680664ed",
                  "target_crn": "crn:v1:bluemix:public:resource-catalog::a/9e16d1fed8aa7e1bd73e7a9d23434a5a::deployment:2fdf0c08-2d32-4f46-84b5-32e0c92fffd8%3Aglobal",
                  "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "allow_cleanup": false,
                  "state": "active",
                  "type": "service_instance",
                  "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                  "dashboard_url": "/objectstorage/crn%3Av1%3Abluemix%3Apublic%3Acloud-object-storage%3Aglobal%3Aa%2F4329073d16d2f3663f74bfa955259139%3A8d7af921-b136-4078-9666-081bd8470d94%3A%3A",
                  "last_operation": {
                    "type": "update",
                    "state": "in progress",
                    "async": true,
                    "description": "Started update instance operation",
                    "cancelable": false,
                    "poll": true
                  },
                  "resource_keys_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/resource_keys",
                  "plan_history": [
                    {
                      "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                      "start_date": "2018-04-19T00:18:53.302077457Z"
                    }
                  ],
                  "migrated": false,
                  "controlled_by": ""
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "422": {
            "$ref": "#/components/responses/UnprocessableEntity"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      }
    },
    "/v2/resource_instances/{id}/resource_keys": {
      "parameters": [
        {
          "name": "id",
          "description": "The resource instance URL-encoded CRN or GUID.",
          "in": "path",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ],
      "get": {
        "tags": [
          "Resource Instances"
        ],
        "summary": "Get a list of all the resource keys for the instance.",
        "description": "You may have many resource keys for one resource instance. For example, you may have a different resource key for each user or each role.",
        "operationId": "list_resource_keys_for_instance",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "description": "Limit on how many items should be returned. The number of items returned may be less than the specified limit if the caller lacks sufficient access to retrieve certain resource keys.",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 100,
              "default": 100
            }
          },
          {
            "name": "start",
            "in": "query",
            "description": "An optional token that indicates the beginning of the page of results to be returned. Any additional query parameters are ignored if a page token is present. If omitted, the first page of results is returned. This value is obtained from the 'start' query parameter in the 'next_url' field of the operation response.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "sort",
            "in": "query",
            "description": "Optional sort property, valid values are `name`, `created_at` and `updated_at`. If specified, the items are sorted by the value of this property.",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "name",
                "created_at",
                "updated_at"
              ],
              "default": "name"
            }
          },
          {
            "name": "order",
            "in": "query",
            "description": "Optional sort order, valid values are `asc` and `desc`.",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "asc",
                "desc"
              ],
              "default": "asc"
            }
          }
        ],
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X GET \\\n  https://resource-controller.cloud.ibm.com/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/resource_keys \\\n  -H \"Authorization: Bearer <IAM token>\""
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "listResourceKeysForInstanceOptions := &resourcecontrollerv2.ListResourceKeysForInstanceOptions{\n",
                      "  ID: &instanceGUID,\n",
                      "}\n",
                      "\n",
                      "pager, err := resourceControllerService.NewResourceKeysForInstancePager(listResourceKeysForInstanceOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "\n",
                      "var allResults []resourcecontrollerv2.ResourceKey\n",
                      "for pager.HasNext() {\n",
                      "  nextPage, err := pager.GetNext()\n",
                      "  if err != nil {\n",
                      "    panic(err)\n",
                      "  }\n",
                      "  allResults = append(allResults, nextPage...)\n",
                      "}\n",
                      "b, _ := json.MarshalIndent(allResults, \"\", \"  \")\n",
                      "fmt.Println(string(b))"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "ListResourceKeysForInstanceOptions listResourceKeysForInstanceOptions = new ListResourceKeysForInstanceOptions.Builder()\n",
                      "  .id(instanceGuid)\n",
                      "  .build();\n",
                      "\n",
                      "ResourceKeysForInstancePager pager = new ResourceKeysForInstancePager(resourceControllerService, listResourceKeysForInstanceOptions);\n",
                      "List<ResourceKey> allResults = new ArrayList<>();\n",
                      "while (pager.hasNext()) {\n",
                      "  List<ResourceKey> nextPage = pager.getNext();\n",
                      "  allResults.addAll(nextPage);\n",
                      "}\n",
                      "\n",
                      "System.out.println(GsonSingleton.getGson().toJson(allResults));"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  id: instanceGuid,\n",
                      "};\n",
                      "\n",
                      "const allResults = [];\n",
                      "try {\n",
                      "  const pager = new ResourceControllerV2.ResourceKeysForInstancePager(\n",
                      "    resourceControllerService, params);\n",
                      "  while (pager.hasNext()) {\n",
                      "    const nextPage = await pager.getNext();\n",
                      "    expect(nextPage).not.toBeNull();\n",
                      "    allResults.push(...nextPage);\n",
                      "  }\n",
                      "  console.log(JSON.stringify(allResults, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "all_results = []\n",
                      "pager = ResourceKeysForInstancePager(\n",
                      "  client=resource_controller_service,\n",
                      "  id=instance_guid,\n",
                      ")\n",
                      "while pager.has_next():\n",
                      "  next_page = pager.get_next()\n",
                      "  assert next_page is not None\n",
                      "  all_results.extend(next_page)\n",
                      "\n",
                      "print(json.dumps(all_results, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.key.retrieve"
            }
          ]
        },
        "x-ibm-events": {
          "description": null,
          "events": [
            {
              "name": "resource-controller.key.retrieve"
            }
          ]
        },
        "responses": {
          "200": {
            "description": "The list of resource keys was successfully retrieved.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceKeysList"
                },
                "example": {
                  "rows_count": 1,
                  "next_url": null,
                  "resources": [
                    {
                      "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                      "guid": "23693f48-aaa2-4079-b0c7-334846eff8d0",
                      "url": "/v2/resource_keys/23693f48-aaa2-4079-b0c7-334846eff8d0",
                      "created_at": "2018-07-02T22:03:43.837979455Z",
                      "updated_at": "2018-07-02T22:03:43.837979455Z",
                      "deleted_at": null,
                      "created_by": "IBMid-5500093BHN",
                      "updated_by": "IBMid-5500093BHN",
                      "deleted_by": "",
                      "source_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                      "role": "crn:v1:bluemix:public:iam::::serviceRole:Writer",
                      "name": "my-instance-key-1",
                      "parameters": {
                        "role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Writer"
                      },
                      "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                      "state": "active",
                      "account_id": "4329073d16d2f3663f74bfa955259139",
                      "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                      "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                      "credentials": {
                        "apikey": "XXXX-YYYY-ZZZZ\"",
                        "endpoints": "https://cos-service-armada-s.us-south.containers.mybluemix.net/endpoints",
                        "iam_apikey_description": "Auto generated apikey during resource-key operation for Instance - crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                        "iam_apikey_name": "auto-generated-apikey-23693f48-aaa2-4079-b0c7-334846eff8d0",
                        "iam_role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Writer",
                        "iam_serviceid_crn": "crn:v1:bluemix:public:iam-identity::a/4329073d16d2f3663f74bfa955259139::serviceid:ServiceId-64c29e4f-422d-468c-a11b-1a8f671b5c89",
                        "resource_instance_id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::"
                      },
                      "iam_compatible": true,
                      "migrated": false,
                      "resource_instance_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      }
    },
    "/v2/resource_instances/{id}/lock": {
      "parameters": [
        {
          "name": "id",
          "description": "The resource instance URL-encoded CRN or GUID.",
          "in": "path",
          "required": true,
          "schema": {
            "type": "string"
          },
          "x-linkback": "#/components/links/ResourceInstanceId"
        }
      ],
      "post": {
        "tags": [
          "Resource Instances"
        ],
        "summary": "Lock a resource instance",
        "description": "Locks a resource instance. A locked instance can not be updated or deleted. It does not affect actions performed on child resources like keys.",
        "operationId": "lock_resource_instance",
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X POST \\\n  https://resource-controller.cloud.ibm.com/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/lock \\\n  -H \"Authorization: Bearer <IAM token>\""
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "lockResourceInstanceOptions := resourceControllerService.NewLockResourceInstanceOptions(\n",
                      "  instanceGUID,\n",
                      ")\n",
                      "\n",
                      "resourceInstance, response, err := resourceControllerService.LockResourceInstance(lockResourceInstanceOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "b, _ := json.MarshalIndent(resourceInstance, \"\", \"  \")\n",
                      "fmt.Println(string(b))"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "LockResourceInstanceOptions lockResourceInstanceOptions = new LockResourceInstanceOptions.Builder()\n",
                      "  .id(instanceGuid)\n",
                      "  .build();\n",
                      "\n",
                      "Response<ResourceInstance> response = resourceControllerService.lockResourceInstance(lockResourceInstanceOptions).execute();\n",
                      "ResourceInstance resourceInstance = response.getResult();\n",
                      "\n",
                      "System.out.println(resourceInstance);"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  id: instanceGuid,\n",
                      "};\n",
                      "\n",
                      "try {\n",
                      "  const res = await resourceControllerService.lockResourceInstance(params);\n",
                      "  console.log(JSON.stringify(res.result, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "resource_instance = resource_controller_service.lock_resource_instance(\n",
                      "  id=instance_guid\n",
                      ").get_result()\n",
                      "\n",
                      "print(json.dumps(resource_instance, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.instance.update"
            }
          ]
        },
        "x-ibm-events": {
          "description": null,
          "events": [
            {
              "name": "resource-controller.instance.update"
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Successfully locked the instance.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceInstance"
                },
                "example": {
                  "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "guid": "8d7af921-b136-4078-9666-081bd8470d94",
                  "url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94",
                  "created_at": "2018-04-19T00:18:53.302077457Z",
                  "updated_at": "2018-04-19T00:18:53.302077457Z",
                  "deleted_at": null,
                  "created_by": "IBMid-5500093BHN",
                  "updated_by": "IBMid-5500093BHN",
                  "deleted_by": "",
                  "scheduled_reclaim_at": null,
                  "restored_at": null,
                  "scheduled_reclaim_by": "",
                  "restored_by": "",
                  "name": "my-instance",
                  "region_id": "global",
                  "account_id": "4329073d16d2f3663f74bfa955259139",
                  "resource_plan_id": "744bfc56-d12c-4866-88d5-dac9139e0e5d",
                  "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                  "resource_group_crn": "crn:v1:bluemix:public:resource-controller::a/4329073d16d2f3663f74bfa955259139::resource-group:0be5ad401ae913d8ff665d92680664ed",
                  "target_crn": "crn:v1:bluemix:public:resource-catalog::a/9e16d1fed8aa7e1bd73e7a9d23434a5a::deployment:2fdf0c08-2d32-4f46-84b5-32e0c92fffd8%3Aglobal",
                  "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "allow_cleanup": false,
                  "state": "active",
                  "type": "service_instance",
                  "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                  "dashboard_url": "/objectstorage/crn%3Av1%3Abluemix%3Apublic%3Acloud-object-storage%3Aglobal%3Aa%2F4329073d16d2f3663f74bfa955259139%3A8d7af921-b136-4078-9666-081bd8470d94%3A%3A",
                  "last_operation": null,
                  "resource_keys_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/resource_keys",
                  "plan_history": [
                    {
                      "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                      "start_date": "2018-04-19T00:18:53.302077457Z"
                    }
                  ],
                  "migrated": false,
                  "controlled_by": "",
                  "locked": true
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "422": {
            "$ref": "#/components/responses/UnprocessableEntity"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      },
      "delete": {
        "tags": [
          "Resource Instances"
        ],
        "summary": "Unlock a resource instance",
        "description": "Unlock a resource instance to update or delete it. Unlocking a resource instance does not affect child resources like keys.",
        "operationId": "unlock_resource_instance",
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X DELETE \\\n  https://resource-controller.cloud.ibm.com/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/lock \\\n  -H \"Authorization: Bearer <IAM token>\""
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "unlockResourceInstanceOptions := resourceControllerService.NewUnlockResourceInstanceOptions(\n",
                      "  instanceGUID,\n",
                      ")\n",
                      "\n",
                      "resourceInstance, response, err := resourceControllerService.UnlockResourceInstance(unlockResourceInstanceOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "b, _ := json.MarshalIndent(resourceInstance, \"\", \"  \")\n",
                      "fmt.Println(string(b))"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "UnlockResourceInstanceOptions unlockResourceInstanceOptions = new UnlockResourceInstanceOptions.Builder()\n",
                      "  .id(instanceGuid)\n",
                      "  .build();\n",
                      "\n",
                      "Response<ResourceInstance> response = resourceControllerService.unlockResourceInstance(unlockResourceInstanceOptions).execute();\n",
                      "ResourceInstance resourceInstance = response.getResult();\n",
                      "\n",
                      "System.out.println(resourceInstance);"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  id: instanceGuid,\n",
                      "};\n",
                      "\n",
                      "try {\n",
                      "  const res = await resourceControllerService.unlockResourceInstance(params);\n",
                      "  console.log(JSON.stringify(res.result, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "resource_instance = resource_controller_service.unlock_resource_instance(\n",
                      "  id=instance_guid\n",
                      ").get_result()\n",
                      "\n",
                      "print(json.dumps(resource_instance, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.instance.update"
            }
          ]
        },
        "x-ibm-events": {
          "description": null,
          "events": [
            {
              "name": "resource-controller.instance.update"
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Successfully unlocked the instance.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceInstance"
                },
                "example": {
                  "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "guid": "8d7af921-b136-4078-9666-081bd8470d94",
                  "url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94",
                  "created_at": "2018-04-19T00:18:53.302077457Z",
                  "updated_at": "2018-04-19T00:18:53.302077457Z",
                  "deleted_at": null,
                  "created_by": "IBMid-5500093BHN",
                  "updated_by": "IBMid-5500093BHN",
                  "deleted_by": "",
                  "scheduled_reclaim_at": null,
                  "restored_at": null,
                  "scheduled_reclaim_by": "",
                  "restored_by": "",
                  "name": "my-instance",
                  "region_id": "global",
                  "account_id": "4329073d16d2f3663f74bfa955259139",
                  "resource_plan_id": "744bfc56-d12c-4866-88d5-dac9139e0e5d",
                  "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                  "resource_group_crn": "crn:v1:bluemix:public:resource-controller::a/4329073d16d2f3663f74bfa955259139::resource-group:0be5ad401ae913d8ff665d92680664ed",
                  "target_crn": "crn:v1:bluemix:public:resource-catalog::a/9e16d1fed8aa7e1bd73e7a9d23434a5a::deployment:2fdf0c08-2d32-4f46-84b5-32e0c92fffd8%3Aglobal",
                  "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "allow_cleanup": false,
                  "state": "active",
                  "type": "service_instance",
                  "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                  "dashboard_url": "/objectstorage/crn%3Av1%3Abluemix%3Apublic%3Acloud-object-storage%3Aglobal%3Aa%2F4329073d16d2f3663f74bfa955259139%3A8d7af921-b136-4078-9666-081bd8470d94%3A%3A",
                  "last_operation": null,
                  "resource_keys_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/resource_keys",
                  "plan_history": [
                    {
                      "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                      "start_date": "2018-04-19T00:18:53.302077457Z"
                    }
                  ],
                  "migrated": false,
                  "controlled_by": "",
                  "locked": false
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "422": {
            "$ref": "#/components/responses/UnprocessableEntity"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      }
    },
    "/v2/resource_instances/{id}/last_operation": {
      "parameters": [
        {
          "name": "id",
          "description": "The resource instance URL-encoded CRN or GUID.",
          "in": "path",
          "required": true,
          "schema": {
            "type": "string"
          },
          "x-linkback": "#/components/links/ResourceInstanceId"
        }
      ],
      "delete": {
        "tags": [
          "Resource Instances"
        ],
        "summary": "Cancel the in progress last operation of the resource instance",
        "description": "Cancel the in progress last operation of the resource instance. This is applicable for instances where the in progress last operation is `cancelable`.",
        "operationId": "cancel_lastop_resource_instance",
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X DELETE \\\n  https://resource-controller.cloud.ibm.com/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/last_operation \\\n  -H 'Authorization: Bearer <>'"
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "cancelLastopResourceInstanceOptions := resourceControllerService.NewCancelLastopResourceInstanceOptions(\n",
                      "  instanceGUID,\n",
                      ")\n",
                      "\n",
                      "resourceInstance, response, err := resourceControllerService.CancelLastopResourceInstance(cancelLastopResourceInstanceOptions)\n",
                      "if err != nil {\n",
                      "  fmt.Println(\"The instance is not cancelable.\")\n",
                      "} else {\n",
                      "  b, _ := json.MarshalIndent(resourceInstance, \"\", \"  \")\n",
                      "  fmt.Println(string(b))\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "resource_instance = resource_controller_service.cancel_lastop_resource_instance(\n",
                      "  id=instance_guid\n",
                      ").get_result()\n",
                      "print(json.dumps(resource_instance, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.instance.delete"
            }
          ]
        },
        "x-ibm-events": {
          "description": null,
          "events": [
            {
              "name": "resource-controller.instance.delete"
            }
          ]
        },
        "responses": {
          "200": {
            "description": "Successfully canceled the in progress last operation of the resource instance.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceInstance"
                },
                "example": {
                  "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "guid": "8d7af921-b136-4078-9666-081bd8470d94",
                  "url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94",
                  "created_at": "2018-04-19T00:18:53.302077457Z",
                  "updated_at": "2018-04-19T00:22:53.302077457Z",
                  "deleted_at": "2018-04-19T00:22:53.302077457Z",
                  "created_by": "IBMid-5401023BHN",
                  "updated_by": "IBMid-5500093BHN",
                  "deleted_by": "IBMid-5500093BHN",
                  "scheduled_reclaim_at": null,
                  "restored_at": null,
                  "scheduled_reclaim_by": "",
                  "restored_by": "",
                  "name": "my-instance",
                  "region_id": "global",
                  "account_id": "4329073d16d2f3663f74bfa955259139",
                  "resource_plan_id": "744bfc56-d12c-4866-88d5-dac9139e0e5d",
                  "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                  "resource_group_crn": "crn:v1:bluemix:public:resource-controller::a/4329073d16d2f3663f74bfa955259139::resource-group:0be5ad401ae913d8ff665d92680664ed",
                  "target_crn": "crn:v1:bluemix:public:resource-catalog::a/9e16d1fed8aa7e1bd73e7a9d23434a5a::deployment:2fdf0c08-2d32-4f46-84b5-32e0c92fffd8%3Aglobal",
                  "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "allow_cleanup": false,
                  "state": "removed",
                  "type": "service_instance",
                  "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                  "dashboard_url": "/objectstorage/crn%3Av1%3Abluemix%3Apublic%3Acloud-object-storage%3Aglobal%3Aa%2F4329073d16d2f3663f74bfa955259139%3A8d7af921-b136-4078-9666-081bd8470d94%3A%3A",
                  "last_operation": {
                    "type": "cancel",
                    "state": "succeeded",
                    "async": false,
                    "description": "Last operation canceled",
                    "cancelable": true,
                    "poll": true
                  },
                  "resource_keys_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/resource_keys",
                  "plan_history": [
                    {
                      "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                      "start_date": "2018-04-19T00:18:53.302077457Z"
                    }
                  ],
                  "migrated": false,
                  "controlled_by": "",
                  "locked": false
                }
              }
            }
          },
          "202": {
            "description": "Last operation cancel request accepted.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceInstance"
                },
                "example": {
                  "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "guid": "8d7af921-b136-4078-9666-081bd8470d94",
                  "url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94",
                  "created_at": "2018-04-19T00:18:53.302077457Z",
                  "updated_at": "2018-04-19T00:22:53.302077457Z",
                  "deleted_at": null,
                  "created_by": "IBMid-5500093BHN",
                  "updated_by": "IBMid-5500093BHN",
                  "deleted_by": "",
                  "scheduled_reclaim_at": null,
                  "restored_at": null,
                  "scheduled_reclaim_by": "",
                  "restored_by": "",
                  "name": "my-instance",
                  "region_id": "global",
                  "account_id": "4329073d16d2f3663f74bfa955259139",
                  "resource_plan_id": "744bfc56-d12c-4866-88d5-dac9139e0e5d",
                  "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                  "resource_group_crn": "crn:v1:bluemix:public:resource-controller::a/4329073d16d2f3663f74bfa955259139::resource-group:0be5ad401ae913d8ff665d92680664ed",
                  "target_crn": "crn:v1:bluemix:public:resource-catalog::a/9e16d1fed8aa7e1bd73e7a9d23434a5a::deployment:2fdf0c08-2d32-4f46-84b5-32e0c92fffd8%3Aglobal",
                  "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "allow_cleanup": false,
                  "state": "provisioning",
                  "type": "service_instance",
                  "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                  "dashboard_url": "/objectstorage/crn%3Av1%3Abluemix%3Apublic%3Acloud-object-storage%3Aglobal%3Aa%2F4329073d16d2f3663f74bfa955259139%3A8d7af921-b136-4078-9666-081bd8470d94%3A%3A",
                  "last_operation": {
                    "type": "cancel",
                    "state": "in progress",
                    "async": true,
                    "description": "Cancelation in progress",
                    "cancelable": true,
                    "poll": true
                  },
                  "resource_keys_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94/resource_keys",
                  "plan_history": [
                    {
                      "resource_plan_id": "2fdf0c08-2d32-4f46-84b5-32e0c92fffd8",
                      "start_date": "2018-04-19T00:18:53.302077457Z"
                    }
                  ],
                  "migrated": false,
                  "controlled_by": "",
                  "locked": false
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "422": {
            "$ref": "#/components/responses/UnprocessableEntity"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          },
          "502": {
            "$ref": "#/components/responses/BadGateway"
          }
        }
      }
    },
    "/v2/resource_keys": {
      "get": {
        "tags": [
          "Resource Keys"
        ],
        "summary": "Get a list of all of the resource keys",
        "description": "View all of the resource keys that exist for all of your resource instances.",
        "operationId": "list_resource_keys",
        "parameters": [
          {
            "name": "guid",
            "in": "query",
            "description": "The GUID of the key.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "name",
            "in": "query",
            "description": "The human-readable name of the key.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "resource_group_id",
            "in": "query",
            "description": "The ID of the resource group.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "resource_id",
            "in": "query",
            "description": "The unique ID of the offering. This value is provided by and stored in the global catalog.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Limit on how many items should be returned. The number of items returned may be less than the specified limit if the caller lacks sufficient access to retrieve certain resource keys.",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 100,
              "default": 100
            }
          },
          {
            "name": "start",
            "in": "query",
            "description": "An optional token that indicates the beginning of the page of results to be returned. Any additional query parameters are ignored if a page token is present. If omitted, the first page of results is returned. This value is obtained from the 'start' query parameter in the 'next_url' field of the operation response.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "updated_from",
            "in": "query",
            "description": "Start date inclusive filter.",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "2021-01-01"
          },
          {
            "name": "updated_to",
            "in": "query",
            "description": "End date inclusive filter.",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "2021-01-01"
          },
          {
            "name": "sort",
            "in": "query",
            "description": "Optional sort property, valid values are `name`, `created_at` and `updated_at`. If specified, the items are sorted by the value of this property.",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "name",
                "created_at",
                "updated_at"
              ],
              "default": "name"
            }
          },
          {
            "name": "order",
            "in": "query",
            "description": "Optional sort order, valid values are `asc` and `desc`.",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "asc",
                "desc"
              ],
              "default": "asc"
            }
          }
        ],
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X GET \\\n  https://resource-controller.cloud.ibm.com/v2/resource_keys \\\n  -H \"Authorization: Bearer <IAM token>\""
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "listResourceKeysOptions := &resourcecontrollerv2.ListResourceKeysOptions{\n",
                      "  Name: &keyName,\n",
                      "}\n",
                      "\n",
                      "pager, err := resourceControllerService.NewResourceKeysPager(listResourceKeysOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "\n",
                      "var allResults []resourcecontrollerv2.ResourceKey\n",
                      "for pager.HasNext() {\n",
                      "  nextPage, err := pager.GetNext()\n",
                      "  if err != nil {\n",
                      "    panic(err)\n",
                      "  }\n",
                      "  allResults = append(allResults, nextPage...)\n",
                      "}\n",
                      "b, _ := json.MarshalIndent(allResults, \"\", \"  \")\n",
                      "fmt.Println(string(b))"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "ListResourceKeysOptions listResourceKeysOptions = new ListResourceKeysOptions.Builder()\n",
                      "  .name(keyName)\n",
                      "  .build();\n",
                      "\n",
                      "ResourceKeysPager pager = new ResourceKeysPager(resourceControllerService, listResourceKeysOptions);\n",
                      "List<ResourceKey> allResults = new ArrayList<>();\n",
                      "while (pager.hasNext()) {\n",
                      "  List<ResourceKey> nextPage = pager.getNext();\n",
                      "  allResults.addAll(nextPage);\n",
                      "}\n",
                      "\n",
                      "System.out.println(GsonSingleton.getGson().toJson(allResults));"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  name: keyName,\n",
                      "};\n",
                      "\n",
                      "const allResults = [];\n",
                      "try {\n",
                      "  const pager = new ResourceControllerV2.ResourceKeysPager(resourceControllerService, params);\n",
                      "  while (pager.hasNext()) {\n",
                      "    const nextPage = await pager.getNext();\n",
                      "    expect(nextPage).not.toBeNull();\n",
                      "    allResults.push(...nextPage);\n",
                      "  }\n",
                      "  console.log(JSON.stringify(allResults, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "all_results = []\n",
                      "pager = ResourceKeysPager(\n",
                      "  client=resource_controller_service,\n",
                      "  name=key_name,\n",
                      ")\n",
                      "while pager.has_next():\n",
                      "  next_page = pager.get_next()\n",
                      "  assert next_page is not None\n",
                      "  all_results.extend(next_page)\n",
                      "\n",
                      "print(json.dumps(all_results, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.key.retrieve"
            }
          ]
        },
        "responses": {
          "200": {
            "description": "The list of resource keys was successfully retrieved.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceKeysList"
                },
                "examples": {
                  "non-redacted-credential": {
                    "summary": "Non-redacted credential example",
                    "value": {
                      "rows_count": 1,
                      "next_url": null,
                      "resources": [
                        {
                          "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                          "guid": "23693f48-aaa2-4079-b0c7-334846eff8d0",
                          "url": "/v2/resource_keys/23693f48-aaa2-4079-b0c7-334846eff8d0",
                          "created_at": "2018-07-02T22:03:43.837979455Z",
                          "updated_at": "2018-07-02T22:03:43.837979455Z",
                          "deleted_at": null,
                          "created_by": "IBMid-5500093BHN",
                          "updated_by": "IBMid-5500093BHN",
                          "deleted_by": "",
                          "source_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                          "role": "crn:v1:bluemix:public:iam::::serviceRole:Writer",
                          "name": "my-instance-key-1",
                          "parameters": {
                            "role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Writer"
                          },
                          "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                          "state": "active",
                          "account_id": "4329073d16d2f3663f74bfa955259139",
                          "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                          "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                          "credentials": {
                            "apikey": "XXXX-YYYY-ZZZZ\"",
                            "endpoints": "https://cos-service-armada-s.us-south.containers.mybluemix.net/endpoints",
                            "iam_apikey_description": "Auto generated apikey during resource-key operation for Instance - crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                            "iam_apikey_name": "auto-generated-apikey-23693f48-aaa2-4079-b0c7-334846eff8d0",
                            "iam_role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Writer",
                            "iam_serviceid_crn": "crn:v1:bluemix:public:iam-identity::a/4329073d16d2f3663f74bfa955259139::serviceid:ServiceId-64c29e4f-422d-468c-a11b-1a8f671b5c89",
                            "resource_instance_id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::"
                          },
                          "iam_compatible": true,
                          "migrated": false,
                          "resource_instance_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94"
                        }
                      ]
                    }
                  },
                  "redacted-credential": {
                    "summary": "Credential REDACTED_EXPLICIT example",
                    "value": {
                      "rows_count": 1,
                      "next_url": null,
                      "resources": [
                        {
                          "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                          "guid": "23693f48-aaa2-4079-b0c7-334846eff8d0",
                          "url": "/v2/resource_keys/23693f48-aaa2-4079-b0c7-334846eff8d0",
                          "created_at": "2018-07-02T22:03:43.837979455Z",
                          "updated_at": "2018-07-02T22:03:43.837979455Z",
                          "deleted_at": null,
                          "created_by": "IBMid-5500093BHN",
                          "updated_by": "IBMid-5500093BHN",
                          "deleted_by": "",
                          "source_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                          "role": "crn:v1:bluemix:public:iam::::serviceRole:Writer",
                          "name": "my-instance-key-1",
                          "parameters": {
                            "role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Writer"
                          },
                          "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                          "state": "active",
                          "account_id": "4329073d16d2f3663f74bfa955259139",
                          "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                          "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                          "credentials": {
                            "REDACTED": "REDACTED_EXPLICIT"
                          },
                          "iam_compatible": true,
                          "migrated": false,
                          "resource_instance_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      },
      "post": {
        "tags": [
          "Resource Keys"
        ],
        "summary": "Create a new resource key",
        "description": "A resource key is a saved credential you can use to authenticate with a resource instance.",
        "operationId": "create_resource_key",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ResourceKeyPost"
              },
              "example": {
                "name": "ExampleResourceKey",
                "parameters": {
                  "exampleParameter": "exampleValue"
                },
                "source": "381fd51a-f251-4f95-aff4-2b03fa8caa63"
              }
            }
          }
        },
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X POST \\\n  https://resource-controller.cloud.ibm.com/v2/resource_keys \\\n  -H \"Authorization: Bearer <IAM token>\" \\\n  -H 'Content-Type: application/json' \\\n  -d '{\n  \"name\": \"my-instance-key-1\",\n  \"source\": \"267bf377-7fa2-43f6-94ec-09103a8e89d4\",\n  \"role\": \"Writer\"\n}'"
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "createResourceKeyOptions := resourceControllerService.NewCreateResourceKeyOptions(\n",
                      "  keyName,\n",
                      "  instanceGUID,\n",
                      ")\n",
                      "\n",
                      "parameters := &resourcecontrollerv2.ResourceKeyPostParameters{}\n",
                      "parameters.SetProperty(\"exampleParameter\", \"exampleValue\")\n",
                      "createResourceKeyOptions.SetParameters(parameters)\n",
                      "\n",
                      "resourceKey, response, err := resourceControllerService.CreateResourceKey(createResourceKeyOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "b, _ := json.MarshalIndent(resourceKey, \"\", \"  \")\n",
                      "fmt.Println(string(b))"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "ResourceKeyPostParameters parameters = new ResourceKeyPostParameters.Builder()\n",
                      "  .add(\"exampleParameter\", \"exampleValue\")\n",
                      "  .build();\n",
                      "CreateResourceKeyOptions createResourceKeyOptions = new CreateResourceKeyOptions.Builder()\n",
                      "  .name(keyName)\n",
                      "  .source(instanceGuid)\n",
                      "  .parameters(parameters)\n",
                      "  .build();\n",
                      "\n",
                      "Response<ResourceKey> response = resourceControllerService.createResourceKey(createResourceKeyOptions).execute();\n",
                      "ResourceKey resourceKey = response.getResult();\n",
                      "\n",
                      "System.out.println(resourceKey);"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const parameters = {\n",
                      "  'exampleParameter': 'exampleValue'\n",
                      "};\n",
                      "\n",
                      "const params = {\n",
                      "  name: keyName,\n",
                      "  source: instanceGuid,\n",
                      "  parameters: parameters,\n",
                      "};\n",
                      "\n",
                      "try {\n",
                      "  const res = await resourceControllerService.createResourceKey(params);\n",
                      "  instanceKeyGuid = res.result.guid;\n",
                      "  console.log(JSON.stringify(res.result, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "parameters = {\n",
                      "  'exampleParameter': 'exampleValue'\n",
                      "}\n",
                      "resource_key = resource_controller_service.create_resource_key(\n",
                      "  name=key_name,\n",
                      "  source=instance_guid,\n",
                      "  parameters=parameters\n",
                      ").get_result()\n",
                      "\n",
                      "print(json.dumps(resource_key, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.key.create"
            }
          ]
        },
        "x-ibm-events": {
          "description": null,
          "events": [
            {
              "name": "resource-controller.key.create"
            }
          ]
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceKey"
                },
                "example": {
                  "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                  "guid": "23693f48-aaa2-4079-b0c7-334846eff8d0",
                  "url": "/v2/resource_keys/23693f48-aaa2-4079-b0c7-334846eff8d0",
                  "created_at": "2018-07-02T22:03:43.837979455Z",
                  "updated_at": "2018-07-02T22:03:43.837979455Z",
                  "deleted_at": null,
                  "created_by": "IBMid-5500093BHN",
                  "updated_by": "IBMid-5500093BHN",
                  "deleted_by": "",
                  "source_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "name": "my-instance-key-1",
                  "role": "crn:v1:bluemix:public:iam::::serviceRole:Writer",
                  "parameters": {
                    "role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Writer"
                  },
                  "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                  "state": "active",
                  "account_id": "4329073d16d2f3663f74bfa955259139",
                  "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                  "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                  "credentials": {
                    "apikey": "XXXX-YYYY-ZZZZ\"",
                    "endpoints": "https://cos-service-armada-s.us-south.containers.mybluemix.net/endpoints",
                    "iam_apikey_description": "Auto generated apikey during resource-key operation for Instance - crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                    "iam_apikey_name": "auto-generated-apikey-23693f48-aaa2-4079-b0c7-334846eff8d0",
                    "iam_role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Writer",
                    "iam_serviceid_crn": "crn:v1:bluemix:public:iam-identity::a/4329073d16d2f3663f74bfa955259139::serviceid:ServiceId-64c29e4f-422d-468c-a11b-1a8f671b5c89",
                    "resource_instance_id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::"
                  },
                  "iam_compatible": true,
                  "migrated": false,
                  "resource_instance_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94"
                }
              }
            },
            "links": {
              "ResourceKeyId": {
                "$ref": "#/components/links/ResourceKeyId"
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      }
    },
    "/v2/resource_keys/{id}": {
      "parameters": [
        {
          "name": "id",
          "description": "The resource key URL-encoded CRN or GUID.",
          "in": "path",
          "required": true,
          "schema": {
            "type": "string"
          },
          "x-linkback": "#/components/links/ResourceKeyId"
        }
      ],
      "get": {
        "tags": [
          "Resource Keys"
        ],
        "summary": "Get resource key",
        "description": "View the details of a resource key by URL-encoded CRN or GUID, like the credentials for the key and who created it.",
        "operationId": "get_resource_key",
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X GET \\\n  https://resource-controller.cloud.ibm.com/v2/resource_keys/23693f48-aaa2-4079-b0c7-334846eff8d0 \\\n  -H \"Authorization: Bearer <IAM token>\""
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "getResourceKeyOptions := resourceControllerService.NewGetResourceKeyOptions(\n",
                      "  instanceKeyGUID,\n",
                      ")\n",
                      "\n",
                      "resourceKey, response, err := resourceControllerService.GetResourceKey(getResourceKeyOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "b, _ := json.MarshalIndent(resourceKey, \"\", \"  \")\n",
                      "fmt.Println(string(b))\n",
                      "if resourceKey.Credentials.Redacted != nil && (*resourceKey.Credentials.Redacted == \"REDACTED\" || *resourceKey.Credentials.Redacted == \"REDACTED_EXPLICIT\") {\n",
                      "  fmt.Println(\"Credentials are redacted with code:\", *resourceKey.Credentials.Redacted, \".The User doesn't have the correct access to view the credentials. Refer to the API documentation for additional details.\")\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "GetResourceKeyOptions getResourceKeyOptions = new GetResourceKeyOptions.Builder()\n",
                      "  .id(instanceKeyGuid)\n",
                      "  .build();\n",
                      "\n",
                      "Response<ResourceKey> response = resourceControllerService.getResourceKey(getResourceKeyOptions).execute();\n",
                      "ResourceKey resourceKey = response.getResult();\n",
                      "\n",
                      "System.out.println(resourceKey);"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  id: instanceKeyGuid,\n",
                      "};\n",
                      "\n",
                      "try {\n",
                      "  const res = await resourceControllerService.getResourceKey(params);\n",
                      "  console.log(JSON.stringify(res.result, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "resource_key = resource_controller_service.get_resource_key(\n",
                      "  id=instance_key_guid\n",
                      ").get_result()\n",
                      "if resource_key.get('credentials') and resource_key.get('credentials').get('REDACTED'):\n",
                      "  print(\"Credentials are redacted with code:\", resource_key.get('credentials').get('REDACTED'), \".The User doesn't have the correct access to view the credentials. Refer to the API documentation for additional details.\")\n",
                      "\n",
                      "print(json.dumps(resource_key, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.key.retrieve"
            }
          ]
        },
        "responses": {
          "200": {
            "description": "The resource key was successfully retrieved.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceKey"
                },
                "examples": {
                  "non-redacted-credential": {
                    "summary": "Non-redacted credential example",
                    "value": {
                      "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                      "guid": "23693f48-aaa2-4079-b0c7-334846eff8d0",
                      "url": "/v2/resource_keys/23693f48-aaa2-4079-b0c7-334846eff8d0",
                      "created_at": "2018-07-02T22:03:43.837979455Z",
                      "updated_at": "2018-07-02T22:03:43.837979455Z",
                      "deleted_at": null,
                      "created_by": "IBMid-5500093BHN",
                      "updated_by": "IBMid-5500093BHN",
                      "deleted_by": "",
                      "source_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                      "role": "crn:v1:bluemix:public:iam::::serviceRole:Writer",
                      "name": "my-instance-key-1",
                      "parameters": {
                        "role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Writer"
                      },
                      "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                      "state": "active",
                      "account_id": "4329073d16d2f3663f74bfa955259139",
                      "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                      "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                      "credentials": {
                        "apikey": "XXXX-YYYY-ZZZZ",
                        "endpoints": "https://cos-service-armada-s.us-south.containers.mybluemix.net/endpoints",
                        "iam_apikey_description": "Auto generated apikey during resource-key operation for Instance - crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                        "iam_apikey_name": "auto-generated-apikey-23693f48-aaa2-4079-b0c7-334846eff8d0",
                        "iam_role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Writer",
                        "iam_serviceid_crn": "crn:v1:bluemix:public:iam-identity::a/4329073d16d2f3663f74bfa955259139::serviceid:ServiceId-64c29e4f-422d-468c-a11b-1a8f671b5c89",
                        "resource_instance_id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::"
                      },
                      "iam_compatible": true,
                      "migrated": false,
                      "resource_instance_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94"
                    }
                  },
                  "redacted-credential": {
                    "summary": "Credential REDACTED_EXPLICIT example",
                    "value": {
                      "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                      "guid": "23693f48-aaa2-4079-b0c7-334846eff8d0",
                      "url": "/v2/resource_keys/23693f48-aaa2-4079-b0c7-334846eff8d0",
                      "created_at": "2018-07-02T22:03:43.837979455Z",
                      "updated_at": "2018-07-02T22:03:43.837979455Z",
                      "deleted_at": null,
                      "created_by": "IBMid-5500093BHN",
                      "updated_by": "IBMid-5500093BHN",
                      "deleted_by": "",
                      "source_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                      "role": "crn:v1:bluemix:public:iam::::serviceRole:Writer",
                      "name": "my-instance-key-1",
                      "parameters": {
                        "role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Writer"
                      },
                      "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                      "state": "active",
                      "account_id": "4329073d16d2f3663f74bfa955259139",
                      "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                      "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                      "credentials": {
                        "REDACTED": "REDACTED_EXPLICIT"
                      },
                      "iam_compatible": true,
                      "migrated": false,
                      "resource_instance_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94"
                    }
                  }
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      },
      "delete": {
        "tags": [
          "Resource Keys"
        ],
        "summary": "Delete a resource key",
        "description": "Deleting a resource key does not affect any resource instance associated with the key.",
        "operationId": "delete_resource_key",
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X DELETE \\\n  https://resource-controller.cloud.ibm.com/v2/resource_keys/23693f48-aaa2-4079-b0c7-334846eff8d0 \\\n  -H \"Authorization: Bearer <IAM token>\""
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "deleteResourceKeyOptions := resourceControllerService.NewDeleteResourceKeyOptions(\n",
                      "  instanceKeyGUID,\n",
                      ")\n",
                      "\n",
                      "response, err := resourceControllerService.DeleteResourceKey(deleteResourceKeyOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "DeleteResourceKeyOptions deleteResourceKeyOptions = new DeleteResourceKeyOptions.Builder()\n",
                      "  .id(instanceKeyGuid)\n",
                      "  .build();\n",
                      "\n",
                      "Response<Void> response = resourceControllerService.deleteResourceKey(deleteResourceKeyOptions).execute();"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  id: instanceKeyGuid,\n",
                      "};\n",
                      "\n",
                      "try {\n",
                      "  await resourceControllerService.deleteResourceKey(params);\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "response = resource_controller_service.delete_resource_key(\n",
                      "  id=instance_key_guid)"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.key.delete"
            }
          ]
        },
        "x-ibm-events": {
          "description": null,
          "events": [
            {
              "name": "resource-controller.key.delete"
            }
          ]
        },
        "responses": {
          "204": {
            "description": "Deleted"
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "410": {
            "$ref": "#/components/responses/Gone"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      },
      "patch": {
        "tags": [
          "Resource Keys"
        ],
        "summary": "Update a resource key",
        "description": "Use the resource key URL-encoded CRN or GUID to update the resource key.",
        "operationId": "update_resource_key",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ResourceKeyPatch"
              },
              "example": {
                "name": "UpdatedExampleResourceKey"
              }
            }
          }
        },
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X PATCH \\\n  https://resource-controller.cloud.ibm.com/v2/resource_keys/23693f48-aaa2-4079-b0c7-334846eff8d0 \\\n  -H \"Authorization: Bearer <IAM token>\" \\\n  -H 'Content-Type: application/json' \\\n    -d '{\n    \"name\": \"my-instance-new-key-1\",\n  }'"
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "updateResourceKeyOptions := resourceControllerService.NewUpdateResourceKeyOptions(\n",
                      "  instanceKeyGUID,\n",
                      "  keyUpdateName,\n",
                      ")\n",
                      "\n",
                      "resourceKey, response, err := resourceControllerService.UpdateResourceKey(updateResourceKeyOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "b, _ := json.MarshalIndent(resourceKey, \"\", \"  \")\n",
                      "fmt.Println(string(b))"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "UpdateResourceKeyOptions updateResourceKeyOptions = new UpdateResourceKeyOptions.Builder()\n",
                      "  .id(instanceKeyGuid)\n",
                      "  .name(keyUpdateName)\n",
                      "  .build();\n",
                      "\n",
                      "Response<ResourceKey> response = resourceControllerService.updateResourceKey(updateResourceKeyOptions).execute();\n",
                      "ResourceKey resourceKey = response.getResult();\n",
                      "\n",
                      "System.out.println(resourceKey);"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  id: instanceKeyGuid,\n",
                      "  name: keyUpdateName,\n",
                      "};\n",
                      "\n",
                      "try {\n",
                      "  const res = await resourceControllerService.updateResourceKey(params);\n",
                      "  console.log(JSON.stringify(res.result, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "resource_key = resource_controller_service.update_resource_key(\n",
                      "  id=instance_key_guid,\n",
                      "  name=key_update_name\n",
                      ").get_result()\n",
                      "\n",
                      "print(json.dumps(resource_key, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "x-ibm-permissions": {
          "description": null,
          "actions": [
            {
              "name": "resource-controller.key.update"
            }
          ]
        },
        "x-ibm-events": {
          "description": null,
          "events": [
            {
              "name": "resource-controller.key.update"
            }
          ]
        },
        "responses": {
          "200": {
            "description": "The resource key was successfully updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResourceKey"
                },
                "example": {
                  "id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                  "guid": "23693f48-aaa2-4079-b0c7-334846eff8d0",
                  "url": "/v2/resource_keys/23693f48-aaa2-4079-b0c7-334846eff8d0",
                  "created_at": "2018-07-02T22:03:43.837979455Z",
                  "updated_at": "2018-07-02T22:03:43.837979455Z",
                  "deleted_at": null,
                  "created_by": "IBMid-5500093BHN",
                  "updated_by": "IBMid-5500093BHN",
                  "deleted_by": "",
                  "source_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                  "role": "crn:v1:bluemix:public:iam::::serviceRole:Writer",
                  "name": "my-instance-new-key-1",
                  "parameters": {
                    "role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Writer"
                  },
                  "crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94:resource-key:23693f48-aaa2-4079-b0c7-334846eff8d0",
                  "state": "active",
                  "account_id": "4329073d16d2f3663f74bfa955259139",
                  "resource_group_id": "0be5ad401ae913d8ff665d92680664ed",
                  "resource_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                  "credentials": {
                    "apikey": "XXXX-YYYY-ZZZZ",
                    "endpoints": "https://cos-service-armada-s.us-south.containers.mybluemix.net/endpoints",
                    "iam_apikey_description": "Auto generated apikey during resource-key operation for Instance - crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::",
                    "iam_apikey_name": "auto-generated-apikey-23693f48-aaa2-4079-b0c7-334846eff8d0",
                    "iam_role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Writer",
                    "iam_serviceid_crn": "crn:v1:bluemix:public:iam-identity::a/4329073d16d2f3663f74bfa955259139::serviceid:ServiceId-64c29e4f-422d-468c-a11b-1a8f671b5c89",
                    "resource_instance_id": "crn:v1:bluemix:public:cloud-object-storage:global:a/4329073d16d2f3663f74bfa955259139:8d7af921-b136-4078-9666-081bd8470d94::"
                  },
                  "iam_compatible": true,
                  "migrated": false,
                  "resource_instance_url": "/v2/resource_instances/8d7af921-b136-4078-9666-081bd8470d94"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "422": {
            "$ref": "#/components/responses/UnprocessableEntity"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      }
    },
    "/v1/reclamations": {
      "get": {
        "tags": [
          "Resource Reclamations"
        ],
        "summary": "Get a list of all reclamations",
        "description": "View all of the resource reclamations that exist for every resource instance.",
        "operationId": "list_reclamations",
        "parameters": [
          {
            "name": "account_id",
            "in": "query",
            "description": "An alpha-numeric value identifying the account ID.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "resource_instance_id",
            "in": "query",
            "description": "The GUID of the resource instance.",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "resource_group_id",
            "in": "query",
            "description": "The ID of the resource group.",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X GET \\\n  https://resource-controller.cloud.ibm.com/v1/reclamations?account_id=b80a8b513ae24e178438b7a18bd8d609 \\\n  -H \"Authorization: Bearer <IAM token>\""
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "listReclamationsOptions := resourceControllerService.NewListReclamationsOptions()\n",
                      "listReclamationsOptions = listReclamationsOptions.SetResourceGroupID(resourceGroupID)\n",
                      "reclamationsList, response, err := resourceControllerService.ListReclamations(listReclamationsOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "b, _ := json.MarshalIndent(reclamationsList, \"\", \"  \")\n",
                      "fmt.Println(string(b))"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "ListReclamationsOptions listReclamationsOptions = new ListReclamationsOptions.Builder()\n",
                      "  .accountId(accountId)\n",
                      "  .build();\n",
                      "\n",
                      "Response<ReclamationsList> response = resourceControllerService.listReclamations(listReclamationsOptions).execute();\n",
                      "ReclamationsList reclamationsList = response.getResult();\n",
                      "\n",
                      "System.out.println(reclamationsList);"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  accountId: accountId,\n",
                      "};\n",
                      "\n",
                      "try {\n",
                      "  const res = await resourceControllerService.listReclamations(params);\n",
                      "  var resources = res.result.resources;\n",
                      "  resources.forEach(reclaim => {\n",
                      "    if (reclaim.resource_instance_id.toString() === instanceGuid) {\n",
                      "      reclamationId = reclaim.id;\n",
                      "    }\n",
                      "  });\n",
                      "  console.log(JSON.stringify(res.result, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "reclamations_list = resource_controller_service.list_reclamations(\n",
                      "  account_id=account_id\n",
                      ").get_result()\n",
                      "\n",
                      "print(json.dumps(reclamations_list, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "responses": {
          "200": {
            "description": "The list of reclamations was successfully retrieved.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReclamationsList"
                },
                "example": {
                  "resources": [
                    {
                      "id": "8b551a81-4af3-47bd-b543-b6e3d512a3db",
                      "entity_id": "dff97f5c-bc5e-4455-b470-411c3edbe49c",
                      "entity_type_id": "98941610-5a79-4778-8b1b-ad115857296b",
                      "entity_crn": "crn:v1:bluemix:public:cloud-object-storage:global:a/b80a8b513ae24e178438b7a18bd8d609:ef8353b4-92d0-456b-a4fb-a15c01ff86a6::",
                      "resource_instance_id": "ef8353b4-92d0-456b-a4fb-a15c01ff86a6",
                      "resource_group_id": "e7d14b0586ed4bcc9f82fc5e05099292",
                      "account_id": "b80a8b513ae24e178438b7a18bd8d609",
                      "policy_id": "6c59484f-dad8-4753-92fd-662fcd4968dc",
                      "state": "SCHEDULED",
                      "target_time": "2019-06-25T10:01:18Z",
                      "created_at": "2019-06-18T10:01:18.847689692Z",
                      "created_by": ""
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      }
    },
    "/v1/reclamations/{id}/actions/{action_name}": {
      "post": {
        "tags": [
          "Resource Reclamations"
        ],
        "summary": "Perform a reclamation action",
        "description": "Reclaim a resource instance so that it can no longer be used, or restore the resource instance so that it's usable again.",
        "operationId": "run_reclamation_action",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The ID associated with the reclamation.",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "action_name",
            "in": "path",
            "description": "The reclamation action name. Specify `reclaim` to delete a resource, or `restore` to restore a resource.",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "reclaim",
                "restore"
              ]
            }
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReclamationActionsPost"
              }
            }
          }
        },
        "x-sdk-operations": {
          "request-examples": {
            "curl": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "lang": "curl",
                    "source": [
                      "curl -X POST \\\n  https://resource-controller.cloud.ibm.com/v1/reclamations/0114be9024c6eede47d08a85ac0c5c43/actions/restore \\\n  -H \"Authorization: Bearer <IAM token>\" \\\n  -H 'Content-Type: application/json' \\\n    -d '{\n    \"request_by\": \"bar\",\n    \"comment\": \"restore resource instance 614fc866-1d4f-4c9e-973e-637f1089a6a1\"\n  }'"
                    ]
                  }
                ]
              }
            ],
            "go": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "runReclamationActionOptions := resourceControllerService.NewRunReclamationActionOptions(\n",
                      "  reclamationID,\n",
                      "  \"reclaim\",\n",
                      ")\n",
                      "\n",
                      "reclamation, response, err := resourceControllerService.RunReclamationAction(runReclamationActionOptions)\n",
                      "if err != nil {\n",
                      "  panic(err)\n",
                      "}\n",
                      "b, _ := json.MarshalIndent(reclamation, \"\", \"  \")\n",
                      "fmt.Println(string(b))"
                    ]
                  }
                ]
              }
            ],
            "java": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "RunReclamationActionOptions runReclamationActionOptions = new RunReclamationActionOptions.Builder()\n",
                      "  .id(reclamationId)\n",
                      "  .actionName(\"reclaim\")\n",
                      "  .build();\n",
                      "\n",
                      "Response<Reclamation> response = resourceControllerService.runReclamationAction(runReclamationActionOptions).execute();\n",
                      "Reclamation reclamation = response.getResult();\n",
                      "\n",
                      "System.out.println(reclamation);"
                    ]
                  }
                ]
              }
            ],
            "node": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "const params = {\n",
                      "  id: reclamationId,\n",
                      "  actionName: 'reclaim',\n",
                      "};\n",
                      "\n",
                      "try {\n",
                      "  const res = await resourceControllerService.runReclamationAction(params);\n",
                      "  console.log(JSON.stringify(res.result, null, 2));\n",
                      "} catch (err) {\n",
                      "  console.warn(err);\n",
                      "}"
                    ]
                  }
                ]
              }
            ],
            "python": [
              {
                "name": "Example request",
                "example": [
                  {
                    "type": "code",
                    "source": [
                      "reclamation = resource_controller_service.run_reclamation_action(\n",
                      "  id=reclamation_id,\n",
                      "  action_name='reclaim'\n",
                      ").get_result()\n",
                      "\n",
                      "print(json.dumps(reclamation, indent=2))"
                    ]
                  }
                ]
              }
            ]
          }
        },
        "responses": {
          "200": {
            "description": "The reclamation action, such as restore or reclaim, was successfully performed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Reclamation"
                },
                "example": {
                  "id": "0114be9024c6eede47d08a85ac0c5c43",
                  "entity_id": "cloudant",
                  "entity_type_id": "98941610-5a79-4778-8b1b-ad115857296b",
                  "entity_crn": "crn:v1:bluemix:public:cloudantnosqldb:us-south:a/b80a8b513ae24e178438b7a18btest:614fc866-1d4f-4c9e-973e-637f10test::",
                  "resource_instance_id": "614fc866-1d4f-4c9e-973e-637f1089a6a1",
                  "resource_group_id": "74f5b3fdbea64fbaafe3e1d9d41test",
                  "account_id": "b80a8b513ae24e178438b7a18btest",
                  "policy_id": "6c59484f-dad8-4753-92fd-662fcd4968dc",
                  "state": "RESTORING",
                  "target_time": "2019-06-24T07:29:56Z",
                  "custom_properties": {
                    "request_by": "bar",
                    "comment": "restore resource instance 614fc866-1d4f-4c9e-973e-637f1089a6a1"
                  },
                  "created_at": "2019-06-17T07:29:56.761106722Z",
                  "created_by": "foo",
                  "updated_at": "2019-06-20T08:27:46.749153Z",
                  "updated_by": "bar"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "IAM": {
        "type": "apiKey",
        "name": "Authorization",
        "in": "header"
      }
    },
    "responses": {
      "BadRequest": {
        "description": "The request could not be understood due to malformed syntax.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ErrorReport"
            }
          }
        }
      },
      "Unauthorized": {
        "description": "Your access token is invalid or authentication of your token failed.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ErrorReport"
            }
          }
        }
      },
      "Forbidden": {
        "description": "Your access token is valid but does not have the necessary permissions to access this resource.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ErrorReport"
            }
          }
        }
      },
      "NotFound": {
        "description": "The resource could not be found.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ErrorReport"
            }
          }
        }
      },
      "Gone": {
        "description": "The resource could was previously deleted and is no longer available.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ErrorReport"
            }
          }
        }
      },
      "UnprocessableEntity": {
        "description": "The request could not be processed.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ErrorReport"
            }
          }
        }
      },
      "TooManyRequests": {
        "description": "Too many requests. Wait a few minutes and try again.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ErrorReport"
            }
          }
        }
      },
      "InternalServerError": {
        "description": "Your request could not be processed. Try again later. If the problem persists, note the `transaction-id` in the response header and contact [IBM Cloud support](https://cloud.ibm.com/unifiedsupport/supportcenter)."
      },
      "BadGateway": {
        "description": "The Server has encountered BadGateway error while connecting to the external components. Try again later. If the problem persists, note the `transaction-id` in the response header and contact [IBM Cloud support](https://cloud.ibm.com/unifiedsupport/supportcenter)."
      }
    },
    "links": {
      "ResourceInstanceId": {
        "description": "Link ResourceInstance id to subsequent operations",
        "operationId": "get_resource_instance",
        "parameters": {
          "id": "$response.body#/guid"
        }
      },
      "ResourceKeyId": {
        "description": "Link ResourceKry id to subsequent operations",
        "operationId": "get_resource_key",
        "parameters": {
          "id": "$response.body#/guid"
        }
      }
    },
    "schemas": {
      "ErrorReport": {
        "description": "Description of an error that occurred in a service request.",
        "properties": {
          "error_code": {
            "description": "The error code encountered.",
            "type": "string",
            "example": "RC-CloudControllerErrorResponse"
          },
          "message": {
            "description": "The error message.",
            "type": "string"
          },
          "status_code": {
            "description": "The status code.",
            "type": "string"
          },
          "transaction_id": {
            "description": "The transaction-id of the request.",
            "type": "string"
          }
        }
      },
      "ResourceInstancePatch": {
        "description": "Updated property values for a resource instance.",
        "type": "object",
        "properties": {
          "name": {
            "description": "The new name of the instance.",
            "type": "string",
            "pattern": "^([\\p{L}\\p{N}._: -]{1,256})$",
            "example": "my-new-instance-name"
          },
          "parameters": {
            "description": "The new configuration options for the instance.<br><br>Set the `onetime_credentials` property to specify whether newly created resource key credentials can be retrieved by using the get resource key or the get a list of all of the resource keys requests.",
            "type": "object",
            "additionalProperties": true
          },
          "resource_plan_id": {
            "description": "The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog.",
            "type": "string",
            "pattern": "^[\\w! \"#$%&'()*+\\-.:;<=>\\[\\]^_{|}]+$",
            "example": "a8dff6d3-d287-4668-a81d-c87c55c2656d"
          },
          "allow_cleanup": {
            "description": "A boolean that dictates if the resource instance should be deleted (cleaned up) during the processing of a region instance delete call.",
            "type": "boolean"
          }
        }
      },
      "ResourceInstancePost": {
        "description": "Property values for the new resource instance.",
        "type": "object",
        "required": [
          "name",
          "target",
          "resource_group",
          "resource_plan_id"
        ],
        "properties": {
          "name": {
            "description": "The name of the instance.",
            "type": "string",
            "pattern": "^([\\p{L}\\p{N}._: -]{1,256})$",
            "example": "my-instance"
          },
          "target": {
            "description": "The deployment CRN or location where the instance should be hosted.",
            "type": "string",
            "example": "us-south"
          },
          "resource_group": {
            "description": "The CRN or ID of the resource group.",
            "type": "string",
            "example": "5c49eabc-f5e8-5881-a37e-2d100a33b3df"
          },
          "resource_plan_id": {
            "description": "The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog.",
            "type": "string",
            "pattern": "^[\\w! \"#$%&'()*+\\-.:;<=>\\[\\]^_{|}]+$",
            "example": "cloudant-standard"
          },
          "tags": {
            "description": "Tags that are attached to the instance after provisioning. These tags can be searched and managed through the Tagging API in IBM Cloud.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "allow_cleanup": {
            "description": "A boolean that dictates if the resource instance should be deleted (cleaned up) during the processing of a region instance delete call.",
            "type": "boolean",
            "default": false
          },
          "parameters": {
            "type": "object",
            "additionalProperties": true,
            "description": "Configuration options represented as key-value pairs that are passed through to the target resource brokers.<br><br> Set the `onetime_credentials` property to specify whether newly created resource key credentials can be retrieved by using the get resource key or the get a list of all of the resource keys requests.<br><br> Set the `subscription_id` property to the ID of the subscription if the targeted plan is a subscription plan."
          }
        }
      },
      "ResourceKeyPatch": {
        "description": "Updated property values for the resource key.",
        "type": "object",
        "required": [
          "name"
        ],
        "properties": {
          "name": {
            "description": "The new name of the key.",
            "type": "string",
            "pattern": "^([\\p{L}\\p{N}._: -]{1,256})$",
            "example": "my-new-key-name"
          }
        }
      },
      "ResourceKeyPost": {
        "description": "Property values for the new resource key.",
        "type": "object",
        "required": [
          "name",
          "source"
        ],
        "properties": {
          "name": {
            "description": "The name of the key.",
            "type": "string",
            "pattern": "^([\\p{L}\\p{N}._: -]{1,256})$",
            "example": "my-key"
          },
          "source": {
            "description": "The CRN or GUID of resource instance.",
            "type": "string",
            "example": "25eba2a9-beef-450b-82cf-f5ad5e36c6dd",
            "x-linkback": "#/components/links/ResourceInstanceId"
          },
          "parameters": {
            "description": "Configuration options represented as key-value pairs. Service defined options are passed through to the target resource brokers, whereas platform defined options are not.",
            "type": "object",
            "additionalProperties": true,
            "properties": {
              "serviceid_crn": {
                "description": "An optional platform defined option to reuse an existing IAM serviceId for the role assignment.",
                "type": "string",
                "example": "crn:v1:bluemix:public:iam-identity::a/9fceaa56d1ab84893af6b9eec5ab81bb::serviceid:ServiceId-fe4c29b5-db13-410a-bacc-b5779a03d393"
              },
              "onetime_credentials": {
                "description": "An optional Boolean that determines whether the created resource key credentials can be retrieved by using get resource key or get a list of all the resource keys requests. The default value is 'onetime_credentials' from the instance.",
                "type": "boolean"
              }
            }
          },
          "role": {
            "description": "The base IAM service role name (Reader, Writer, or Manager), or the service or custom role CRN. Refer to service’s documentation for supported roles.",
            "type": "string",
            "default": "Writer",
            "example": "Writer"
          }
        }
      },
      "ResourceInstance": {
        "description": "A resource instance.",
        "type": "object",
        "properties": {
          "id": {
            "description": "The ID associated with the instance.",
            "type": "string"
          },
          "guid": {
            "description": "The GUID of the instance.",
            "type": "string"
          },
          "url": {
            "description": "When you provision a new resource, a relative URL path is created identifying the location of the instance.",
            "type": "string"
          },
          "created_at": {
            "description": "The date when the instance was created.",
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "description": "The date when the instance was last updated.",
            "type": "string",
            "format": "date-time"
          },
          "deleted_at": {
            "description": "The date when the instance was deleted.",
            "type": "string",
            "format": "date-time"
          },
          "created_by": {
            "description": "The subject who created the instance.",
            "type": "string"
          },
          "updated_by": {
            "description": "The subject who updated the instance.",
            "type": "string"
          },
          "deleted_by": {
            "description": "The subject who deleted the instance.",
            "type": "string"
          },
          "scheduled_reclaim_at": {
            "description": "The date when the instance was scheduled for reclamation.",
            "type": "string",
            "format": "date-time"
          },
          "restored_at": {
            "description": "The date when the instance under reclamation was restored.",
            "type": "string",
            "format": "date-time"
          },
          "restored_by": {
            "description": "The subject who restored the instance back from reclamation.",
            "type": "string"
          },
          "scheduled_reclaim_by": {
            "description": "The subject who initiated the instance reclamation.",
            "type": "string"
          },
          "name": {
            "description": "The human-readable name of the instance.",
            "type": "string"
          },
          "region_id": {
            "description": "The deployment location where the instance was provisioned.",
            "type": "string"
          },
          "account_id": {
            "description": "An alpha-numeric value identifying the account ID.",
            "type": "string"
          },
          "reseller_channel_id": {
            "description": "The unique ID of the reseller channel where the instance was provisioned from.",
            "type": "string"
          },
          "resource_plan_id": {
            "description": "The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog.",
            "type": "string"
          },
          "resource_group_id": {
            "description": "The ID of the resource group.",
            "type": "string"
          },
          "resource_group_crn": {
            "description": "The CRN of the resource group.",
            "type": "string"
          },
          "target_crn": {
            "description": "The deployment CRN as defined in the global catalog where the instance is provisioned.",
            "type": "string"
          },
          "onetime_credentials": {
            "description": "Whether newly created resource key credentials can be retrieved by using get resource key or get a list of all of the resource keys requests.",
            "type": "boolean"
          },
          "parameters": {
            "type": "object",
            "additionalProperties": true,
            "description": "The current configuration parameters of the instance from the previous operation. Any future operation on the instance may reset this these values."
          },
          "allow_cleanup": {
            "description": "A boolean that dictates if the resource instance should be deleted (cleaned up) during the processing of a region instance delete call.",
            "type": "boolean"
          },
          "crn": {
            "description": "The full Cloud Resource Name (CRN) associated with the instance. For more information about this format, see [Cloud Resource Names](https://cloud.ibm.com/docs/overview?topic=overview-crn).",
            "type": "string"
          },
          "state": {
            "description": "The current state of the instance. For example, if the instance is deleted, it will return removed.",
            "type": "string",
            "enum": [
              "active",
              "inactive",
              "removed",
              "pending_removal",
              "pending_reclamation",
              "failed",
              "provisioning",
              "pre_provisioning"
            ]
          },
          "type": {
            "description": "The type of the instance, for example, `service_instance`.",
            "type": "string"
          },
          "sub_type": {
            "description": "The sub-type of instance, for example, `cfaas`.",
            "type": "string"
          },
          "resource_id": {
            "description": "The unique ID of the offering. This value is provided by and stored in the global catalog.",
            "type": "string"
          },
          "dashboard_url": {
            "description": "The resource-broker-provided URL to access administrative features of the instance.",
            "type": "string"
          },
          "last_operation": {
            "description": "The status of the last operation requested on the instance.",
            "type": "object",
            "additionalProperties": true,
            "allOf": [
              {
                "$ref": "#/components/schemas/LastOperation"
              }
            ]
          },
          "resource_keys_url": {
            "description": "The relative path to the resource keys for the instance.",
            "type": "string"
          },
          "plan_history": {
            "description": "The plan history of the instance.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PlanHistoryItem"
            }
          },
          "migrated": {
            "description": "A boolean that dictates if the resource instance was migrated from a previous CF instance.",
            "type": "boolean"
          },
          "extensions": {
            "description": "Additional instance properties, contributed by the service and/or platform, are represented as key-value pairs.",
            "type": "object",
            "additionalProperties": true
          },
          "controlled_by": {
            "description": "The CRN of the resource that has control of the instance.",
            "type": "string"
          },
          "locked": {
            "description": "A boolean that dictates if the resource instance is locked or not.",
            "type": "boolean"
          },
          "subscription_id": {
            "description": "The subscription ID associated with the instance.",
            "type": "string"
          }
        }
      },
      "PlanHistoryItem": {
        "description": "An element of the plan history of the instance.",
        "type": "object",
        "required": [
          "resource_plan_id",
          "start_date"
        ],
        "properties": {
          "resource_plan_id": {
            "description": "The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog.",
            "type": "string"
          },
          "start_date": {
            "description": "The date on which the plan was changed.",
            "type": "string",
            "format": "date-time"
          },
          "requestor_id": {
            "description": "The subject who made the plan change.",
            "type": "string",
            "format": "string"
          }
        }
      },
      "LastOperation": {
        "description": "An element of the last operation of the instance.",
        "type": "object",
        "required": [
          "type",
          "state",
          "async",
          "description",
          "cancelable",
          "poll"
        ],
        "properties": {
          "type": {
            "description": "The last operation type of the resource instance.",
            "type": "string"
          },
          "state": {
            "description": "The last operation state of the resoure instance. This indicates if the resource's last operation is in progress, succeeded or failed.",
            "type": "string",
            "enum": [
              "in progress",
              "succeeded",
              "failed"
            ]
          },
          "sub_type": {
            "description": "The last operation sub type of the resoure instance.",
            "type": "string"
          },
          "async": {
            "description": "A boolean that indicates if the resource is provisioned asynchronously or not.",
            "type": "boolean"
          },
          "description": {
            "description": "The description of the status of last operation.",
            "type": "string"
          },
          "reason_code": {
            "description": "Optional string that states the reason code for the last operation state change.",
            "type": "string"
          },
          "poll_after": {
            "description": "A field which indicates the time after which the instance's last operation is to be polled.",
            "type": "number"
          },
          "cancelable": {
            "description": "A boolean that indicates if the resource's last operation is cancelable or not.",
            "type": "boolean"
          },
          "poll": {
            "description": "A boolean that indicates if the resource broker's last operation can be polled or not.",
            "type": "boolean"
          }
        }
      },
      "ResourceInstancesList": {
        "description": "A list of resource instances.",
        "type": "object",
        "required": [
          "rows_count",
          "next_url",
          "resources"
        ],
        "properties": {
          "rows_count": {
            "description": "The number of resource instances in `resources`.",
            "type": "integer"
          },
          "next_url": {
            "description": "The URL for requesting the next page of results.",
            "type": "string"
          },
          "resources": {
            "description": "A list of resource instances.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ResourceInstance"
            }
          }
        }
      },
      "ResourceKey": {
        "description": "A resource key.",
        "type": "object",
        "properties": {
          "id": {
            "description": "The ID associated with the key.",
            "type": "string"
          },
          "guid": {
            "description": "The GUID of the key.",
            "type": "string"
          },
          "url": {
            "description": "When you created a new key, a relative URL path is created identifying the location of the key.",
            "type": "string"
          },
          "created_at": {
            "description": "The date when the key was created.",
            "type": "string",
            "format": "date-time"
          },
          "updated_at": {
            "description": "The date when the key was last updated.",
            "type": "string",
            "format": "date-time"
          },
          "deleted_at": {
            "description": "The date when the key was deleted.",
            "type": "string",
            "format": "date-time"
          },
          "created_by": {
            "description": "The subject who created the key.",
            "type": "string"
          },
          "updated_by": {
            "description": "The subject who updated the key.",
            "type": "string"
          },
          "deleted_by": {
            "description": "The subject who deleted the key.",
            "type": "string"
          },
          "source_crn": {
            "description": "The CRN of resource instance associated to the key.",
            "type": "string"
          },
          "name": {
            "description": "The human-readable name of the key.",
            "type": "string"
          },
          "crn": {
            "description": "The full Cloud Resource Name (CRN) associated with the key. For more information about this format, see [Cloud Resource Names](https://cloud.ibm.com/docs/overview?topic=overview-crn).",
            "type": "string"
          },
          "state": {
            "description": "The state of the key.",
            "type": "string"
          },
          "account_id": {
            "description": "An alpha-numeric value identifying the account ID.",
            "type": "string"
          },
          "resource_group_id": {
            "description": "The ID of the resource group.",
            "type": "string"
          },
          "resource_id": {
            "description": "The unique ID of the offering. This value is provided by and stored in the global catalog.",
            "type": "string"
          },
          "onetime_credentials": {
            "description": "Whether newly created resource key credentials can be retrieved by using get resource key or get a list of all of the resource keys requests.",
            "type": "boolean"
          },
          "credentials": {
            "description": "The credentials for the key. Additional key-value pairs are passed through from the resource brokers. After a credential is created for a service, it can be viewed at any time for users that need the API key value. However, all users must have the correct level of access to see the details of a credential that includes the API key value. For additional details, see [viewing a credential](https://cloud.ibm.com/docs/account?topic=account-service_credentials&interface=ui#viewing-credentials-ui) or the service’s documentation.",
            "allOf": [
              {
                "$ref": "#/components/schemas/Credentials"
              }
            ]
          },
          "iam_compatible": {
            "description": "Specifies whether the key’s credentials support IAM.",
            "type": "boolean"
          },
          "migrated": {
            "description": "A boolean that dictates if the key was migrated from a previous CF instance.",
            "type": "boolean"
          },
          "resource_instance_url": {
            "description": "The relative path to the resource.",
            "type": "string"
          }
        }
      },
      "ResourceKeysList": {
        "description": "A list of resource keys.",
        "type": "object",
        "required": [
          "rows_count",
          "next_url",
          "resources"
        ],
        "properties": {
          "rows_count": {
            "description": "The number of resource keys in `resources`.",
            "type": "integer"
          },
          "next_url": {
            "description": "The URL for requesting the next page of results.",
            "type": "string"
          },
          "resources": {
            "description": "A list of resource keys.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ResourceKey"
            }
          }
        }
      },
      "Credentials": {
        "description": "The credentials for a resource.",
        "type": "object",
        "properties": {
          "REDACTED": {
            "description": "If present, the user doesn't have the correct access to view the credentials and the details are redacted.  The string value identifies the level of access that's required to view the credential. For additional information, see [viewing a credential](https://cloud.ibm.com/docs/account?topic=account-service_credentials&interface=ui#viewing-credentials-ui).",
            "type": "string",
            "enum": [
              "REDACTED",
              "REDACTED_EXPLICIT"
            ]
          },
          "apikey": {
            "description": "The API key for the credentials.",
            "type": "string"
          },
          "iam_apikey_description": {
            "description": "The optional description of the API key.",
            "type": "string"
          },
          "iam_apikey_name": {
            "description": "The name of the API key.",
            "type": "string"
          },
          "iam_role_crn": {
            "description": "The CRN for the role of the credentials.",
            "type": "string"
          },
          "iam_serviceid_crn": {
            "description": "The CRN for the service ID of the credentials.",
            "type": "string"
          }
        },
        "additionalProperties": {
          "description": "Additional key-value pairs from the resource broker."
        }
      },
      "ReclamationsList": {
        "description": "A list of reclamations.",
        "type": "object",
        "properties": {
          "resources": {
            "description": "A list of reclamations.",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Reclamation"
            }
          }
        }
      },
      "ReclamationActionsPost": {
        "description": "Perform a reclamation action.",
        "type": "object",
        "properties": {
          "request_by": {
            "description": "The request initiator, if different from the request token.",
            "type": "string"
          },
          "comment": {
            "description": "A comment to describe the action.",
            "type": "string"
          }
        }
      },
      "Reclamation": {
        "description": "A reclamation.",
        "type": "object",
        "properties": {
          "id": {
            "description": "The ID associated with the reclamation.",
            "type": "string"
          },
          "entity_id": {
            "description": "The ID of the entity for the reclamation.",
            "type": "string"
          },
          "entity_type_id": {
            "description": "The ID of the entity type for the reclamation.",
            "type": "string"
          },
          "entity_crn": {
            "description": "The CRN of the entity for the reclamation.",
            "type": "string"
          },
          "resource_instance_id": {
            "description": "The ID of the resource instance.",
            "type": "string"
          },
          "resource_group_id": {
            "description": "The ID of the resource group.",
            "type": "string"
          },
          "account_id": {
            "description": "An alpha-numeric value identifying the account ID.",
            "type": "string"
          },
          "policy_id": {
            "description": "The ID of policy for the reclamation.",
            "type": "string"
          },
          "state": {
            "description": "The state of the reclamation.",
            "type": "string"
          },
          "target_time": {
            "description": "The target time that the reclamation retention period end.",
            "type": "string"
          },
          "custom_properties": {
            "description": "The custom properties of the reclamation.",
            "type": "object",
            "additionalProperties": true
          },
          "created_at": {
            "description": "The date when the reclamation was created.",
            "type": "string",
            "format": "date-time"
          },
          "created_by": {
            "description": "The subject who created the reclamation.",
            "type": "string"
          },
          "updated_at": {
            "description": "The date when the reclamation was last updated.",
            "type": "string",
            "format": "date-time"
          },
          "updated_by": {
            "description": "The subject who updated the reclamation.",
            "type": "string"
          }
        }
      }
    }
  }
}