### POST /v2/resource_instances Source: https://cloud.ibm.com/apidocs/resource-controller/resource-controller.json 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. ```markdown ### Parameters - **Entity-Lock** (boolean, header, optional): 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. ### Request Body **Content-Type:** application/json - **name** (string) (required): The name of the instance. (example: "my-instance") - **target** (string) (required): The deployment CRN or location where the instance should be hosted. (example: "us-south") - **resource_group** (string) (required): The CRN or ID of the resource group. (example: "5c49eabc-f5e8-5881-a37e-2d100a33b3df") - **resource_plan_id** (string) (required): The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog. (example: "cloudant-standard") - **tags** (array (string)): Tags that are attached to the instance after provisioning. These tags can be searched and managed through the Tagging API in IBM Cloud. - **allow_cleanup** (boolean): A boolean that dictates if the resource instance should be deleted (cleaned up) during the processing of a region instance delete call. - **parameters** (object): Configuration options represented as key-value pairs that are passed through to the target resource brokers.

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.

Set the `subscription_id` property to the ID of the subscription if the targeted plan is a subscription plan. ### Responses #### 201 - The resource instance was provisioned. **ResourceInstance** - **id** (string): The ID associated with the instance. - **guid** (string): The GUID of the instance. - **url** (string): When you provision a new resource, a relative URL path is created identifying the location of the instance. - **created_at** (string (date-time)): The date when the instance was created. - **updated_at** (string (date-time)): The date when the instance was last updated. - **deleted_at** (string (date-time)): The date when the instance was deleted. - **created_by** (string): The subject who created the instance. - **updated_by** (string): The subject who updated the instance. - **deleted_by** (string): The subject who deleted the instance. - **scheduled_reclaim_at** (string (date-time)): The date when the instance was scheduled for reclamation. - **restored_at** (string (date-time)): The date when the instance under reclamation was restored. - **restored_by** (string): The subject who restored the instance back from reclamation. - **scheduled_reclaim_by** (string): The subject who initiated the instance reclamation. - **name** (string): The human-readable name of the instance. - **region_id** (string): The deployment location where the instance was provisioned. - **account_id** (string): An alpha-numeric value identifying the account ID. - **reseller_channel_id** (string): The unique ID of the reseller channel where the instance was provisioned from. - **resource_plan_id** (string): The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog. - **resource_group_id** (string): The ID of the resource group. - **resource_group_crn** (string): The CRN of the resource group. - **target_crn** (string): The deployment CRN as defined in the global catalog where the instance is provisioned. - **onetime_credentials** (boolean): 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. - **parameters** (object): The current configuration parameters of the instance from the previous operation. Any future operation on the instance may reset this these values. - **allow_cleanup** (boolean): A boolean that dictates if the resource instance should be deleted (cleaned up) during the processing of a region instance delete call. - **crn** (string): 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). - **state** (string (active|inactive|removed|pending_removal|pending_reclamation|failed|provisioning|pre_provisioning)): The current state of the instance. For example, if the instance is deleted, it will return removed. ("active"|"inactive"|"removed"|"pending_removal"|"pending_reclamation"|"failed"|"provisioning"|"pre_provisioning") - **type** (string): The type of the instance, for example, `service_instance`. - **sub_type** (string): The sub-type of instance, for example, `cfaas`. - **resource_id** (string): The unique ID of the offering. This value is provided by and stored in the global catalog. - **dashboard_url** (string): The resource-broker-provided URL to access administrative features of the instance. - **last_operation** (object): An element of the last operation of the instance. - **type** (string) (required): The last operation type of the resource instance. - **state** (string (in progress|succeeded|failed)) (required): The last operation state of the resoure instance. This indicates if the resource's last operation is in progress, succeeded or failed. ("in progress"|"succeeded"|"failed") - **sub_type** (string): The last operation sub type of the resoure instance. - **async** (boolean) (required): A boolean that indicates if the resource is provisioned asynchronously or not. - **description** (string) (required): The description of the status of last operation. - **reason_code** (string): Optional string that states the reason code for the last operation state change. - **poll_after** (number): A field which indicates the time after which the instance's last operation is to be polled. - **cancelable** (boolean) (required): A boolean that indicates if the resource's last operation is cancelable or not. - **poll** (boolean) (required): A boolean that indicates if the resource broker's last operation can be polled or not. - **resource_keys_url** (string): The relative path to the resource keys for the instance. - **plan_history** (array (PlanHistoryItem)): The plan history of the instance. Array items: - **resource_plan_id** (string) (required): The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog. - **start_date** (string (date-time)) (required): The date on which the plan was changed. - **requestor_id** (string (string)): The subject who made the plan change. - **migrated** (boolean): A boolean that dictates if the resource instance was migrated from a previous CF instance. - **extensions** (object): Additional instance properties, contributed by the service and/or platform, are represented as key-value pairs. - **controlled_by** (string): The CRN of the resource that has control of the instance. - **locked** (boolean): A boolean that dictates if the resource instance is locked or not. - **subscription_id** (string): The subscription ID associated with the instance. #### 202 - 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. **ResourceInstance** - **id** (string): The ID associated with the instance. - **guid** (string): The GUID of the instance. - **url** (string): When you provision a new resource, a relative URL path is created identifying the location of the instance. - **created_at** (string (date-time)): The date when the instance was created. - **updated_at** (string (date-time)): The date when the instance was last updated. - **deleted_at** (string (date-time)): The date when the instance was deleted. - **created_by** (string): The subject who created the instance. - **updated_by** (string): The subject who updated the instance. - **deleted_by** (string): The subject who deleted the instance. - **scheduled_reclaim_at** (string (date-time)): The date when the instance was scheduled for reclamation. - **restored_at** (string (date-time)): The date when the instance under reclamation was restored. - **restored_by** (string): The subject who restored the instance back from reclamation. - **scheduled_reclaim_by** (string): The subject who initiated the instance reclamation. - **name** (string): The human-readable name of the instance. - **region_id** (string): The deployment location where the instance was provisioned. - **account_id** (string): An alpha-numeric value identifying the account ID. - **reseller_channel_id** (string): The unique ID of the reseller channel where the instance was provisioned from. - **resource_plan_id** (string): The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog. - **resource_group_id** (string): The ID of the resource group. - **resource_group_crn** (string): The CRN of the resource group. - **target_crn** (string): The deployment CRN as defined in the global catalog where the instance is provisioned. - **onetime_credentials** (boolean): 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. - **parameters** (object): The current configuration parameters of the instance from the previous operation. Any future operation on the instance may reset this these values. - **allow_cleanup** (boolean): A boolean that dictates if the resource instance should be deleted (cleaned up) during the processing of a region instance delete call. - **crn** (string): 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). - **state** (string (active|inactive|removed|pending_removal|pending_reclamation|failed|provisioning|pre_provisioning)): The current state of the instance. For example, if the instance is deleted, it will return removed. ("active"|"inactive"|"removed"|"pending_removal"|"pending_reclamation"|"failed"|"provisioning"|"pre_provisioning") - **type** (string): The type of the instance, for example, `service_instance`. - **sub_type** (string): The sub-type of instance, for example, `cfaas`. - **resource_id** (string): The unique ID of the offering. This value is provided by and stored in the global catalog. - **dashboard_url** (string): The resource-broker-provided URL to access administrative features of the instance. - **last_operation** (object): An element of the last operation of the instance. - **type** (string) (required): The last operation type of the resource instance. - **state** (string (in progress|succeeded|failed)) (required): The last operation state of the resoure instance. This indicates if the resource's last operation is in progress, succeeded or failed. ("in progress"|"succeeded"|"failed") - **sub_type** (string): The last operation sub type of the resoure instance. - **async** (boolean) (required): A boolean that indicates if the resource is provisioned asynchronously or not. - **description** (string) (required): The description of the status of last operation. - **reason_code** (string): Optional string that states the reason code for the last operation state change. - **poll_after** (number): A field which indicates the time after which the instance's last operation is to be polled. - **cancelable** (boolean) (required): A boolean that indicates if the resource's last operation is cancelable or not. - **poll** (boolean) (required): A boolean that indicates if the resource broker's last operation can be polled or not. - **resource_keys_url** (string): The relative path to the resource keys for the instance. - **plan_history** (array (PlanHistoryItem)): The plan history of the instance. Array items: - **resource_plan_id** (string) (required): The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog. - **start_date** (string (date-time)) (required): The date on which the plan was changed. - **requestor_id** (string (string)): The subject who made the plan change. - **migrated** (boolean): A boolean that dictates if the resource instance was migrated from a previous CF instance. - **extensions** (object): Additional instance properties, contributed by the service and/or platform, are represented as key-value pairs. - **controlled_by** (string): The CRN of the resource that has control of the instance. - **locked** (boolean): A boolean that dictates if the resource instance is locked or not. - **subscription_id** (string): The subscription ID associated with the instance. #### 400 - response **ErrorReport** #### 401 - response **ErrorReport** #### 403 - response **ErrorReport** #### 404 - response **ErrorReport** #### 429 - response **ErrorReport** #### 500 - response 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). ### Example Usage ```bash curl -X POST "https://resource-controller.cloud.ibm.com/v2/resource_instances" \ -H "Content-Type: application/json" \ -d '{ "name": "my-instance", "target": "us-south", "resource_group": "5c49eabc-f5e8-5881-a37e-2d100a33b3df", "resource_plan_id": "cloudant-standard", "tags": [ "string" ], "allow_cleanup": "false", "parameters": "value" }' ``` ``` -------------------------------- ### GET /v2/resource_instances/{id}/resource_keys Source: https://cloud.ibm.com/apidocs/resource-controller/resource-controller.json 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. ```markdown ### Parameters - **limit** (integer, query, optional): 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. - **start** (string, query, optional): 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. ### Responses #### 200 - The list of resource keys was successfully retrieved. **ResourceKeysList** - **rows_count** (integer) (required): The number of resource keys in `resources`. - **next_url** (string) (required): The URL for requesting the next page of results. - **resources** (array (ResourceKey)) (required): A list of resource keys. Array items: - **id** (string): The ID associated with the key. - **guid** (string): The GUID of the key. - **url** (string): When you created a new key, a relative URL path is created identifying the location of the key. - **created_at** (string (date-time)): The date when the key was created. - **updated_at** (string (date-time)): The date when the key was last updated. - **deleted_at** (string (date-time)): The date when the key was deleted. - **created_by** (string): The subject who created the key. - **updated_by** (string): The subject who updated the key. - **deleted_by** (string): The subject who deleted the key. - **source_crn** (string): The CRN of resource instance associated to the key. - **name** (string): The human-readable name of the key. - **crn** (string): 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). - **state** (string): The state of the key. - **account_id** (string): An alpha-numeric value identifying the account ID. - **resource_group_id** (string): The ID of the resource group. - **resource_id** (string): The unique ID of the offering. This value is provided by and stored in the global catalog. - **onetime_credentials** (boolean): 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. - **credentials** (object): The credentials for a resource. - **REDACTED** (string (REDACTED|REDACTED_EXPLICIT)): 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). ("REDACTED"|"REDACTED_EXPLICIT") - **apikey** (string): The API key for the credentials. - **iam_apikey_description** (string): The optional description of the API key. - **iam_apikey_name** (string): The name of the API key. - **iam_role_crn** (string): The CRN for the role of the credentials. - **iam_serviceid_crn** (string): The CRN for the service ID of the credentials. - **iam_compatible** (boolean): Specifies whether the key’s credentials support IAM. - **migrated** (boolean): A boolean that dictates if the key was migrated from a previous CF instance. - **resource_instance_url** (string): The relative path to the resource. #### 401 - response **ErrorReport** #### 403 - response **ErrorReport** #### 429 - response **ErrorReport** #### 500 - response 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). ### Example Usage ```bash curl -X GET "https://resource-controller.cloud.ibm.com/v2/resource_instances/{id}/resource_keys?limit=100&start=string" ``` ``` -------------------------------- ### GET /v2/resource_keys Source: https://cloud.ibm.com/apidocs/resource-controller/resource-controller.json View all of the resource keys that exist for all of your resource instances. ```markdown ### Parameters - **guid** (string, query, optional): The GUID of the key. - **name** (string, query, optional): The human-readable name of the key. - **resource_group_id** (string, query, optional): The ID of the resource group. - **resource_id** (string, query, optional): The unique ID of the offering. This value is provided by and stored in the global catalog. - **limit** (integer, query, optional): 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. - **start** (string, query, optional): 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. - **updated_from** (string, query, optional): Start date inclusive filter. - **updated_to** (string, query, optional): End date inclusive filter. ### Responses #### 200 - The list of resource keys was successfully retrieved. **ResourceKeysList** - **rows_count** (integer) (required): The number of resource keys in `resources`. - **next_url** (string) (required): The URL for requesting the next page of results. - **resources** (array (ResourceKey)) (required): A list of resource keys. Array items: - **id** (string): The ID associated with the key. - **guid** (string): The GUID of the key. - **url** (string): When you created a new key, a relative URL path is created identifying the location of the key. - **created_at** (string (date-time)): The date when the key was created. - **updated_at** (string (date-time)): The date when the key was last updated. - **deleted_at** (string (date-time)): The date when the key was deleted. - **created_by** (string): The subject who created the key. - **updated_by** (string): The subject who updated the key. - **deleted_by** (string): The subject who deleted the key. - **source_crn** (string): The CRN of resource instance associated to the key. - **name** (string): The human-readable name of the key. - **crn** (string): 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). - **state** (string): The state of the key. - **account_id** (string): An alpha-numeric value identifying the account ID. - **resource_group_id** (string): The ID of the resource group. - **resource_id** (string): The unique ID of the offering. This value is provided by and stored in the global catalog. - **onetime_credentials** (boolean): 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. - **credentials** (object): The credentials for a resource. - **REDACTED** (string (REDACTED|REDACTED_EXPLICIT)): 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). ("REDACTED"|"REDACTED_EXPLICIT") - **apikey** (string): The API key for the credentials. - **iam_apikey_description** (string): The optional description of the API key. - **iam_apikey_name** (string): The name of the API key. - **iam_role_crn** (string): The CRN for the role of the credentials. - **iam_serviceid_crn** (string): The CRN for the service ID of the credentials. - **iam_compatible** (boolean): Specifies whether the key’s credentials support IAM. - **migrated** (boolean): A boolean that dictates if the key was migrated from a previous CF instance. - **resource_instance_url** (string): The relative path to the resource. #### 401 - response **ErrorReport** #### 403 - response **ErrorReport** #### 429 - response **ErrorReport** #### 500 - response 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). ### Example Usage ```bash curl -X GET "https://resource-controller.cloud.ibm.com/v2/resource_keys?guid=string&name=string&resource_group_id=string&resource_id=string&limit=100&start=string&updated_from=string&updated_to=string" ``` ``` -------------------------------- ### GET /v2/resource_instances Source: https://cloud.ibm.com/apidocs/resource-controller/resource-controller.json 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. ```markdown ### Parameters - **guid** (string, query, optional): The GUID of the instance. - **name** (string, query, optional): The human-readable name of the instance. - **resource_group_id** (string, query, optional): The ID of the resource group. - **resource_id** (string, query, optional): The unique ID of the offering. This value is provided by and stored in the global catalog. - **resource_plan_id** (string, query, optional): The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog. - **type** (string, query, optional): The type of the instance, for example, `service_instance`. - **sub_type** (string, query, optional): The sub-type of instance, for example, `kms`. - **subscription_id** (string, query, optional): The ID of the subscription. - **limit** (integer, query, optional): 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. - **start** (string, query, optional): 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. - **state** (string (active|inactive|failed|pending_reclamation|provisioning|pre_provisioning|removed), query, optional): The state of the instance. If not specified, instances in state `active`, `inactive`, `failed`, `provisioning` and `pre_provisioning` are returned. - **updated_from** (string, query, optional): Start date inclusive filter. - **updated_to** (string, query, optional): End date inclusive filter. ### Responses #### 200 - The list of resource instances was successfully retrieved. **ResourceInstancesList** - **rows_count** (integer) (required): The number of resource instances in `resources`. - **next_url** (string) (required): The URL for requesting the next page of results. - **resources** (array (ResourceInstance)) (required): A list of resource instances. Array items: - **id** (string): The ID associated with the instance. - **guid** (string): The GUID of the instance. - **url** (string): When you provision a new resource, a relative URL path is created identifying the location of the instance. - **created_at** (string (date-time)): The date when the instance was created. - **updated_at** (string (date-time)): The date when the instance was last updated. - **deleted_at** (string (date-time)): The date when the instance was deleted. - **created_by** (string): The subject who created the instance. - **updated_by** (string): The subject who updated the instance. - **deleted_by** (string): The subject who deleted the instance. - **scheduled_reclaim_at** (string (date-time)): The date when the instance was scheduled for reclamation. - **restored_at** (string (date-time)): The date when the instance under reclamation was restored. - **restored_by** (string): The subject who restored the instance back from reclamation. - **scheduled_reclaim_by** (string): The subject who initiated the instance reclamation. - **name** (string): The human-readable name of the instance. - **region_id** (string): The deployment location where the instance was provisioned. - **account_id** (string): An alpha-numeric value identifying the account ID. - **reseller_channel_id** (string): The unique ID of the reseller channel where the instance was provisioned from. - **resource_plan_id** (string): The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog. - **resource_group_id** (string): The ID of the resource group. - **resource_group_crn** (string): The CRN of the resource group. - **target_crn** (string): The deployment CRN as defined in the global catalog where the instance is provisioned. - **onetime_credentials** (boolean): 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. - **parameters** (object): The current configuration parameters of the instance from the previous operation. Any future operation on the instance may reset this these values. - **allow_cleanup** (boolean): A boolean that dictates if the resource instance should be deleted (cleaned up) during the processing of a region instance delete call. - **crn** (string): 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). - **state** (string (active|inactive|removed|pending_removal|pending_reclamation|failed|provisioning|pre_provisioning)): The current state of the instance. For example, if the instance is deleted, it will return removed. ("active"|"inactive"|"removed"|"pending_removal"|"pending_reclamation"|"failed"|"provisioning"|"pre_provisioning") - **type** (string): The type of the instance, for example, `service_instance`. - **sub_type** (string): The sub-type of instance, for example, `cfaas`. - **resource_id** (string): The unique ID of the offering. This value is provided by and stored in the global catalog. - **dashboard_url** (string): The resource-broker-provided URL to access administrative features of the instance. - **last_operation** (object): An element of the last operation of the instance. - **type** (string) (required): The last operation type of the resource instance. - **state** (string (in progress|succeeded|failed)) (required): The last operation state of the resoure instance. This indicates if the resource's last operation is in progress, succeeded or failed. ("in progress"|"succeeded"|"failed") - **sub_type** (string): The last operation sub type of the resoure instance. - **async** (boolean) (required): A boolean that indicates if the resource is provisioned asynchronously or not. - **description** (string) (required): The description of the status of last operation. - **reason_code** (string): Optional string that states the reason code for the last operation state change. - **poll_after** (number): A field which indicates the time after which the instance's last operation is to be polled. - **cancelable** (boolean) (required): A boolean that indicates if the resource's last operation is cancelable or not. - **poll** (boolean) (required): A boolean that indicates if the resource broker's last operation can be polled or not. - **resource_keys_url** (string): The relative path to the resource keys for the instance. - **plan_history** (array (PlanHistoryItem)): The plan history of the instance. Array items: - **resource_plan_id** (string) (required): The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog. - **start_date** (string (date-time)) (required): The date on which the plan was changed. - **requestor_id** (string (string)): The subject who made the plan change. - **migrated** (boolean): A boolean that dictates if the resource instance was migrated from a previous CF instance. - **extensions** (object): Additional instance properties, contributed by the service and/or platform, are represented as key-value pairs. - **controlled_by** (string): The CRN of the resource that has control of the instance. - **locked** (boolean): A boolean that dictates if the resource instance is locked or not. - **subscription_id** (string): The subscription ID associated with the instance. #### 401 - response **ErrorReport** #### 403 - response **ErrorReport** #### 429 - response **ErrorReport** #### 500 - response 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). ### Example Usage ```bash curl -X GET "https://resource-controller.cloud.ibm.com/v2/resource_instances?guid=string&name=string&resource_group_id=string&resource_id=string&resource_plan_id=string&type=string&sub_type=string&subscription_id=string&limit=100&start=string&state=active&updated_from=string&updated_to=string" ``` ``` -------------------------------- ### GET /v2/resource_instances/{id} Source: https://cloud.ibm.com/apidocs/resource-controller/resource-controller.json 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. ```markdown ### Responses #### 200 - The resource instance was successfully retrieved. **ResourceInstance** - **id** (string): The ID associated with the instance. - **guid** (string): The GUID of the instance. - **url** (string): When you provision a new resource, a relative URL path is created identifying the location of the instance. - **created_at** (string (date-time)): The date when the instance was created. - **updated_at** (string (date-time)): The date when the instance was last updated. - **deleted_at** (string (date-time)): The date when the instance was deleted. - **created_by** (string): The subject who created the instance. - **updated_by** (string): The subject who updated the instance. - **deleted_by** (string): The subject who deleted the instance. - **scheduled_reclaim_at** (string (date-time)): The date when the instance was scheduled for reclamation. - **restored_at** (string (date-time)): The date when the instance under reclamation was restored. - **restored_by** (string): The subject who restored the instance back from reclamation. - **scheduled_reclaim_by** (string): The subject who initiated the instance reclamation. - **name** (string): The human-readable name of the instance. - **region_id** (string): The deployment location where the instance was provisioned. - **account_id** (string): An alpha-numeric value identifying the account ID. - **reseller_channel_id** (string): The unique ID of the reseller channel where the instance was provisioned from. - **resource_plan_id** (string): The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog. - **resource_group_id** (string): The ID of the resource group. - **resource_group_crn** (string): The CRN of the resource group. - **target_crn** (string): The deployment CRN as defined in the global catalog where the instance is provisioned. - **onetime_credentials** (boolean): 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. - **parameters** (object): The current configuration parameters of the instance from the previous operation. Any future operation on the instance may reset this these values. - **allow_cleanup** (boolean): A boolean that dictates if the resource instance should be deleted (cleaned up) during the processing of a region instance delete call. - **crn** (string): 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). - **state** (string (active|inactive|removed|pending_removal|pending_reclamation|failed|provisioning|pre_provisioning)): The current state of the instance. For example, if the instance is deleted, it will return removed. ("active"|"inactive"|"removed"|"pending_removal"|"pending_reclamation"|"failed"|"provisioning"|"pre_provisioning") - **type** (string): The type of the instance, for example, `service_instance`. - **sub_type** (string): The sub-type of instance, for example, `cfaas`. - **resource_id** (string): The unique ID of the offering. This value is provided by and stored in the global catalog. - **dashboard_url** (string): The resource-broker-provided URL to access administrative features of the instance. - **last_operation** (object): An element of the last operation of the instance. - **type** (string) (required): The last operation type of the resource instance. - **state** (string (in progress|succeeded|failed)) (required): The last operation state of the resoure instance. This indicates if the resource's last operation is in progress, succeeded or failed. ("in progress"|"succeeded"|"failed") - **sub_type** (string): The last operation sub type of the resoure instance. - **async** (boolean) (required): A boolean that indicates if the resource is provisioned asynchronously or not. - **description** (string) (required): The description of the status of last operation. - **reason_code** (string): Optional string that states the reason code for the last operation state change. - **poll_after** (number): A field which indicates the time after which the instance's last operation is to be polled. - **cancelable** (boolean) (required): A boolean that indicates if the resource's last operation is cancelable or not. - **poll** (boolean) (required): A boolean that indicates if the resource broker's last operation can be polled or not. - **resource_keys_url** (string): The relative path to the resource keys for the instance. - **plan_history** (array (PlanHistoryItem)): The plan history of the instance. Array items: - **resource_plan_id** (string) (required): The unique ID of the plan associated with the offering. This value is provided by and stored in the global catalog. - **start_date** (string (date-time)) (required): The date on which the plan was changed. - **requestor_id** (string (string)): The subject who made the plan change. - **migrated** (boolean): A boolean that dictates if the resource instance was migrated from a previous CF instance. - **extensions** (object): Additional instance properties, contributed by the service and/or platform, are represented as key-value pairs. - **controlled_by** (string): The CRN of the resource that has control of the instance. - **locked** (boolean): A boolean that dictates if the resource instance is locked or not. - **subscription_id** (string): The subscription ID associated with the instance. #### 401 - response **ErrorReport** #### 403 - response **ErrorReport** #### 404 - response **ErrorReport** #### 429 - response **ErrorReport** #### 500 - response 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). ### Example Usage ```bash curl -X GET "https://resource-controller.cloud.ibm.com/v2/resource_instances/{id}" ``` ``` -------------------------------- ### GET /v1/reclamations Source: https://cloud.ibm.com/apidocs/resource-controller/resource-controller.json View all of the resource reclamations that exist for every resource instance. ```markdown ### Parameters - **account_id** (string, query, optional): An alpha-numeric value identifying the account ID. - **resource_instance_id** (string, query, optional): The GUID of the resource instance. - **resource_group_id** (string, query, optional): The ID of the resource group. ### Responses #### 200 - The list of reclamations was successfully retrieved. **ReclamationsList** - **resources** (array (Reclamation)): A list of reclamations. Array items: - **id** (string): The ID associated with the reclamation. - **entity_id** (string): The ID of the entity for the reclamation. - **entity_type_id** (string): The ID of the entity type for the reclamation. - **entity_crn** (string): The CRN of the entity for the reclamation. - **resource_instance_id** (string): The ID of the resource instance. - **resource_group_id** (string): The ID of the resource group. - **account_id** (string): An alpha-numeric value identifying the account ID. - **policy_id** (string): The ID of policy for the reclamation. - **state** (string): The state of the reclamation. - **target_time** (string): The target time that the reclamation retention period end. - **custom_properties** (object): The custom properties of the reclamation. - **created_at** (string (date-time)): The date when the reclamation was created. - **created_by** (string): The subject who created the reclamation. - **updated_at** (string (date-time)): The date when the reclamation was last updated. - **updated_by** (string): The subject who updated the reclamation. #### 401 - response **ErrorReport** #### 403 - response **ErrorReport** #### 404 - response **ErrorReport** #### 429 - response **ErrorReport** #### 500 - response 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). ### Example Usage ```bash curl -X GET "https://resource-controller.cloud.ibm.com/v1/reclamations?account_id=string&resource_instance_id=string&resource_group_id=string" ``` ```