{"revision":"c10276e953456835cdbb1f3a60d58ae1980be353","document":{"id":464,"path":"api-reference/rest-apis/applications-api.md","title":"CdmApplicationsApi","bundle":null,"doc_type":null,"release":"australia","body":"\n# CdmApplicationsApi\n\nThe CdmApplicationsApi provides endpoints that enable you to `uploadzoominsoftware.io/utah-devops/`configuration data to the component, collection, deployable, and component variable folders found in the DevOps Config Workspace UI. It also has endpoints that enable you to export deployable configuration data to your DevOps pipeline and manage shared components and shared applications.\n\nThe export and upload endpoints use an asynchronous queuing implementation. With this type of implementation, you first call the desired export or upload request endpoint. These endpoints queue your request and return a request identifier. You then use this request identifier to call the appropriate status endpoint, one for uploads and a different one for exports, to obtain the status of the upload/export. For export requests, once the export is complete, you can also request the content of the export.\n\nThis API does not provide endpoints that perform simple retrieval of application records. To retrieve these records, use the [Table](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/c_TableAPI.md) API.\n\nYou must have one of the following roles to access this API:\n\n-   Scripted REST CDM View ACL \\(sn\\_cdm.cdm.viewer\\)\n-   Scripted REST CDM Editor ACL \\(sn\\_cdm.cdm\\_editor\\)\n\nIn addition, the Configuration Data Management \\(CDM\\) plugin must be activated for this API to be available in an instance.\n\nFor additional information on Configuration Data Management and the DevOps Config Workspace UI, see [Uploading your config data](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-upload-process.md).\n\nFor additional information on shared components and shared libraries, see [Sharing components among applications — Component libraries](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-component-libraries.md).\n\n**Parent Topic:**[REST API reference](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/api-rest.md)\n\n## CdmApplicationsApi - DELETE /sn\\_cdm/applications/deployables\n\nDeletes a specified Configuration Data Management \\(CDM\\) deployable.\n\nThe caller of this endpoint must have the CDM Admin role.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/deployables`\n\nDefault URL: `/api/sn_cdm/applications/deployables`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappName\n\n</td><td>\n\nRequired. Name of the CDM application to which the deployable is associated.Data type: String\n\nTable: CDM Deployable \\[sn\\_cdm\\_deployable\\]\n\n</td></tr><tr><td>\n\nname\n\n</td><td>\n\nName of the deployable to delete.Data type: String\n\nTable: CDM Deployable \\[sn\\_cdm\\_deployable\\]\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Header|Description|\n|------|-----------|\n|Accept|Data format of the response body. Only supports **application/json**.|\n\n|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Status code|Description|\n|-----------|-----------|\n|200|Successful. The request was successfully processed.|\n|400|Bad Request. A bad request type or malformed request was detected.|\n|500|Internal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.|\n\n### Response body parameters\n\n|Name|Description|\n|----|-----------|\n|None||\n\n### cURL request\n\nThe following code example shows how to remove a deployable.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/deployables?appName=testApp&name=Dep-1\" \\ \n--request DELETE \\ \n--header \"Accept:application/json\" \\ \n--user 'username':'password1' \n```\n\nFor a successful deletion of the deployable, no response is returned other than the HTTP status code.\n\n```\nNone - results defined by the HTTP status code\n```\n\n## CdmApplicationsApi - DELETE /sn\\_cdm/applications/shared\\_components\n\nRemoves the shared component usage reference from a specified Configuration Data Management \\(CDM\\) application.\n\nThe CDM Admin role is required to access this endpoint.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/shared_components`\n\nDefault URL: `/api/sn_cdm/applications/shared_components`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappName\n\n</td><td>\n\nRequired. Name of the application from which to remove the specified shared component association. The specified application must have the type field set to \"shared\\_library\".Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr><tr><td>\n\nchangesetNumber\n\n</td><td id=\"changesetNumber-changeset-entry\">\n\nRequired. Unique identifier of the associated changeset, such as \"Chset-10\".\n\nData type: String\n\nTable: CDM Changeset \\[sn\\_cdm\\_changeset\\]\n\n</td></tr><tr><td>\n\nsharedComponentName\n\n</td><td>\n\nRequired. Unique name of the shared component to remove from the specified application.Data type: String\n\nTable: CDM Shared Component \\[sn\\_cdm\\_shared\\_component\\]\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table class=\"rest_api_request_headers\"><thead><tr><th>\n\nHeader\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nAccept\n\n</td><td id=\"accept-entry-RESTAPI\">\n\nData format of the response body. Supported types: **application/json** or **application/xml**. Default: **application/json**\n\n</td></tr></tbody>\n</table>|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Status code|Description|\n|-----------|-----------|\n|200|Successful. The request was successfully processed.|\n|400|Bad Request. A bad request type or malformed request was detected.|\n|500|Internal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.|\n\n### Response body parameters\n\n<table><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nresult\n\n</td><td>\n\nEmpty. The HTTP status code indicates the result of the call.\n\n</td></tr><tr><td>\n\nerror\n\n</td><td>\n\nIf an error occurred during processing, the details about the error.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr><td>\n\nstatus\n\n</td><td>\n\nError status of the request.Possible values: failure\n\nData type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following code example shows how to delete the \"paymentService-V1.1\" shared component from the \"App1\" application.\n\n```\ncurl \"https://instance-name.service-now.com/api/sn_cdm/applications/shared_components?appName=App1&sharedComponentName=paymentService-V1.1&changesetNumber=Chset-25\" \\ \n--request DELETE \\ \n--header \"Accept:application/json\" \\ \n--user 'username':'password' \n```\n\nResponse:\n\n```\n\"\"\n```\n\n## CdmApplicationsApi - GET /sn\\_cdm/applications/deployables/exports/\\{export\\_id\\}/content\n\nReturns the content associated with a specified configuration data export request.\n\nOnly call this endpoint once you have received a `complete` response from the [CdmApplicationsApi - GET /sn\\_cdm/applications/deployables/exports/\\{export\\_id\\}/status](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint. If you call this endpoint before the export is complete, a 400 status error is returned.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/deployables/exports/{export_id}/content`\n\nDefault URL: `/api/sn_cdm/applications/deployables/exports/{export_id}/content`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr><tr><td>\n\nexport\\_id\n\n</td><td>\n\nUnique identifier for the export request whose configuration data to return. This value is returned by the [CdmApplicationsApi - POST /sn\\_cdm/applications/deployables/exports](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint.\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Header|Description|\n|------|-----------|\n|Accept|Data format of the response body. Only supports **application/json**.|\n\n|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Status code|Description|\n|-----------|-----------|\n|200|Successful. The request was successfully processed.|\n|400|Bad Request. A bad request type or malformed request was detected.|\n|500|Internal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.|\n\n### Response body parameters \\(JSON or XML\\)\n\n<table><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nerrors\n\n</td><td>\n\nDescription of the errors encountered during export.Data type: String\n\n</td></tr><tr><td>\n\nexport\\_id\n\n</td><td>\n\nExport request ID. Same as that passed into the endpoint.Data type: String\n\n</td></tr><tr><td>\n\nexporter\\_result\n\n</td><td>\n\nContent of the specified configuration data export.Data type:\n\n-   JSON object: If the request was to export data in JSON format.\n-   String: If the request was to export data in any other format.\n\n</td></tr><tr><td>\n\nrequest\\_id\n\n</td><td>\n\nExport request ID. Same as that passed into the endpoint.Data type: String\n\n</td></tr><tr><td>\n\nstate\n\n</td><td>\n\nCurrent state of the specified export.Possible values:\n\n-   completed\n-   error\n-   in\\_progress\n-   new\n-   ready\n\nData type: String\n\nTable: In state column of the CDM Request Queue \\[sn\\_cdm\\_request\\_queue\\] table.\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following example requests the configuration data of an export request with the ID of 3ab14a7d53b1301096edddeeff7b12f.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/deployables/exports/3ab14a7d53b1301096edddeeff7b12f/content\" \\ \n--request GET \\ \n--header \"Accept:application/json\" \\\n--user 'username':'password' \n```\n\nThe following shows the possible return results.\n\n```\n// Successful completion of the export request\n{ \n  \"result\": { \n    \"export_id\": \"3ab14a7d53b1301096edddeeff7b12f\" \n    \"exporter_result\": \"DEP1.COMP.cdi_1=cdi-1-value\" \n  } \n}\n\n// Response when an incorrect export_id is passed. Note: Status code is 200.\n{ \n  \"result\": { \n    \"request_id\": \"3ab14a7d53b1301096edddeeff7b12e\", \n    \"state\": \"error\", \n    \"errors\": \"Invalid requestId '3ab14a7d53b1301096edddeeff7b12fe'\", \n    \"export_id\": \"3ab14a7d53b1301096edddeeff7b12e\" \n  } \n}\n```\n\n## CdmApplicationsApi - GET /sn\\_cdm/applications/deployables/exports/\\{export\\_id\\}/status\n\nReturns the current status of the specified configuration data export request.\n\nUse the [CdmApplicationsApi - POST /sn\\_cdm/applications/deployables/exports](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to make an export request.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/deployables/exports/{export_id}/status`\n\nDefault URL: `/api/sn_cdm/applications/deployables/exports/{export_id}/status`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr><tr><td>\n\nexport\\_id\n\n</td><td>\n\nSys\\_id of the export request whose status to return. This value is returned by the [CdmApplicationsApi - POST /sn\\_cdm/applications/deployables/exports](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint.\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Header|Description|\n|------|-----------|\n|Accept|Data format of the response body. Only supports **application/json**.|\n\n|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Status code|Description|\n|-----------|-----------|\n|200|Successful. The request was successfully processed.|\n|400|Bad Request. A bad request type or malformed request was detected.|\n|500|Internal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.|\n\n### Response body parameters \\(JSON or XML\\)\n\n<table><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nerrors\n\n</td><td>\n\nDescription of the errors encountered during export.Data type: String\n\n</td></tr><tr><td>\n\nexport\\_id\n\n</td><td>\n\nExport request ID. Same as that passed into the endpoint.Data type: String\n\n</td></tr><tr><td>\n\nexporter\\_result\n\n</td><td>\n\nDetails about the associated error.Data type: Object\n\n</td></tr><tr><td>\n\nexporter\\_result.errors\n\n</td><td>\n\nDescription of the error\\(s\\) encountered during export.Data type: Array\n\n</td></tr><tr><td>\n\nexporter\\_result.execution\\_id\n\n</td><td>\n\nUnique identifier for the exporter execution record.Data type: String\n\nTable: CDM Exporter Execution \\[sn\\_cdm\\_exporter\\_execution\\]\n\n</td></tr><tr><td>\n\nexporter\\_result.state\n\n</td><td>\n\nCurrent state of the specified export.Possible values:\n\n-   complete\n-   error\n-   in\\_progress\n-   new\n\nData type: String\n\nTable: CDM Exporter Execution \\[sn\\_cdm\\_exporter\\_execution\\]\n\n</td></tr><tr><td>\n\nrequest\\_id\n\n</td><td>\n\nExport request ID. Same as that passed into the endpoint.Data type: String\n\n</td></tr><tr><td>\n\nstate\n\n</td><td>\n\nCurrent state of the specified export.Possible values:\n\n-   completed\n-   error\n-   in\\_progress\n-   new\n-   ready\n\nData type: String\n\nTable: In state column of the CDM Request Queue \\[sn\\_cdm\\_request\\_queue\\] table.\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following example requests the status of an export with the ID of 3ab14a7d53b1301096edddeeff7b12f.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/deployables/exports/3ab14a7d53b1301096edddeeff7b12f/status\" \\ \n--request GET \\ \n--header \"Accept:application/json\" \\\n--user 'username':'password' \n```\n\nThe following are the possible return results.\n\n```\n// Successful completion of the export request\n{ \n  \"result\": { \n    \"state\": \"completed\", \n    \"export_id\": \"3ab14a7d53b1301096edddeeff7b12f0\" \n  } \n}\n\n// Response when an incorrect export_id is passed. Note: Status code is 200.\n{ \n  \"result\": { \n    \"request_id\": \"3ac8e1b05311301096edddeeff7b123c\", \n    \"state\": \"error\", \n    \"errors\": \"Invalid requestId '3ac8e1b05311301096edddeeff7b123c'\", \n    \"export_id\": \"3ac8e1b05311301096edddeeff7b123c\" \n  } \n} \n\n// Response when the export encounters an error. The exporter_result array contains the error information. Note: Status code is 200.\n{ \n  \"result\": { \n    \"state\": \"completed\", \n    \"export_id\": \"24536c3353f9301096edddeeff7b12b1\", \n    \"exporter_result\": { \n      \"execution_id\": \"81536c3353f9301096edddeeff7b129e\", \n      \"state\": \"failure\", \n      \"errors\": [ \n        \"Snapshot 'SNA-001-published-non_compliant' has not passed validation. All snapshots of deployable '/ApplicationA/deployables/DEP3' are required to pass validation\" \n      ] \n    } \n  } \n}\n```\n\n## CdmApplicationsApi - GET /sn\\_cdm/applications/shared\\_components\n\nReturns the list of shared components used by a specified application. You can also specify to only return those shared components that have a new version available.\n\nThe CDM Admin role is required to access this endpoint.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/shared_components`\n\nDefault URL: `/api/sn_cdm/applications/shared_components`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappName\n\n</td><td>\n\nRequired. Name of the application whose list of shared components you want returned. The type field of the application must be set to shared\\_library.Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr><tr><td>\n\nwithUpdatesOnly\n\n</td><td>\n\nFlag that indicates whether to only return shared components that have a new updated version available.Valid values:\n\n-   true: Only return shared components that have a new updated version available.\n-   false: Return all shared components used by the specified application.\n\nDefault: false\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table class=\"rest_api_request_headers\"><thead><tr><th>\n\nHeader\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nAccept\n\n</td><td id=\"accept-entry-RESTAPI\">\n\nData format of the response body. Supported types: **application/json** or **application/xml**. Default: **application/json**\n\n</td></tr></tbody>\n</table>|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Status code|Description|\n|-----------|-----------|\n|200|Successful. The request was successfully processed.|\n|400|Bad Request. A bad request type or malformed request was detected.|\n|500|Internal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.|\n\n### Response body parameters\n\n<table><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\ncurrentVersion\n\n</td><td>\n\nCurrent version of the CDM application. Data type: Number \\(Integer\\)\n\n</td></tr><tr><td>\n\ncurrentVersionName\n\n</td><td>\n\nName of shared component version currently in use.Data type: String\n\n</td></tr><tr><td>\n\ndescription\n\n</td><td>\n\nDescription of shared component.Data type: String\n\n</td></tr><tr><td>\n\nerror\n\n</td><td>\n\nIf an error occurred during processing, the details about the error.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr><td>\n\nname\n\n</td><td>\n\nUnique name of the shared component.Data type: String\n\n</td></tr><tr><td>\n\nsharedLibraryName\n\n</td><td>\n\nName of shared library to which the shared component belongs.Data type: String\n\n</td></tr><tr><td>\n\nstatus\n\n</td><td>\n\nError status of the request.Possible values: failure\n\nData type: String\n\n</td></tr><tr><td>\n\nupdateVersionName\n\n</td><td>\n\nName of shared component version available for update.Data type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following code example shows how to call this endpoint to retrieve the shared components that have a new version used by \"App1\".\n\n```\ncurl \"https://instance-name.service-now.com/api/sn_cdm/applications/shared_components?updatesOnly=true&appName=App1\" \\ \n--request GET \\ \n--header \"Accept:application/json\" \\ \n--user 'username':'password' \n```\n\nResponse:\n\n```\n{ \n  \"result\": [\n    {\n      \"name\": \"Component_Name\",\n      \"description\": \"”,\n      \"sharedLibraryName\": \"Shared Library\",\n      \"currentVersion\": \"2\",\n      \"currentVersionName\": \"Component_A-v2.shc\",\n      \"updateVersionName\": \"Component_A-v3.shc\"\n    } \n  ]\n}\n```\n\n## CdmApplicationsApi - GET /sn\\_cdm/applications/shared\\_libraries/components/applications\n\nReturns a map of shared components and the applications that use them that are within a specified library.\n\nThe CDM Admin role is required to access this endpoint.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/shared_libraries/components/applications`\n\nDefault URL: `/api/sn_cdm/applications/shared_libraries/components/applications`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nsharedComponentName\n\n</td><td>\n\nRequired. Name of the shared component to include in the map.Data type: String\n\nTable: CDM Shared Component \\[sn\\_cdm\\_shared\\_component\\]\n\n</td></tr><tr><td>\n\nsharedLibraryName\n\n</td><td>\n\nRequired. Name of the shared library to include in the map. The specified application must have the type field set to \"shared\\_library\".Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table class=\"rest_api_request_headers\"><thead><tr><th>\n\nHeader\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nAccept\n\n</td><td id=\"accept-entry-RESTAPI\">\n\nData format of the response body. Supported types: **application/json** or **application/xml**. Default: **application/json**\n\n</td></tr></tbody>\n</table>|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Status code|Description|\n|-----------|-----------|\n|200|Successful. The request was successfully processed.|\n|400|Bad Request. A bad request type or malformed request was detected.|\n|500|Internal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.|\n\n### Response body parameters\n\n<table><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\ndescription\n\n</td><td>\n\nDescription of application using shared component Data type: String\n\n</td></tr><tr><td>\n\nerror\n\n</td><td>\n\nIf an error occurred during processing, the details about the error.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr><td>\n\nmanaged\\_by\\_group\n\n</td><td>\n\nComma-separated list of sys\\_ids of the groups that can manage the application.Data type: String\n\n</td></tr><tr><td>\n\nname\n\n</td><td>\n\nUnique name of the application using the component.Data type: String\n\n</td></tr><tr><td>\n\nstatus\n\n</td><td>\n\nError status of the request.Possible values: failure\n\nData type: String\n\n</td></tr><tr><td>\n\nsys\\_id\n\n</td><td>\n\nSys\\_id of the application utilizing the shared component.Data type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following code example shows how to call this endpoint to retrieve the map that shows the applications in the \"OracleG-Library-10\" shared library that use the \"paymentService-V1.1\" shared component.\n\n```\ncurl \"https://instance-name.service-now.com/api/sn_cdm/applications/shared_libraries/components/applications?sharedLibraryName=OracleG-Library-10&sharedComponentName=paymentService-V1.1\" \\ \n--request GET \\ \n--header \"Accept:application/json\" \\ \n--user 'username':'password'\n```\n\nResponse:\n\n```\n{\n  \"result\": {\n    \"component_name\": [\n      { \n        \"name\": \"App Name\",\n        \"description\": \"desc\",\n        \"managed_by_group\": null,\n        \"sys_id\": \"4e7808bb1b371110636e0fe0604bcb08\"\n      }, \n      {\n        \"name\": \"Config App\",\n        \"description\": \"desc\",\n        \"managed_by_group\": null,\n        \"sys_id\": \"55a75cfb1b771110636e0fe0604bcb5c\"\n      },\n      {\n        \"name\": \"Database App\",\n        \"description\": \"desc\",\n        \"managed_by_group\": null,\n        \"sys_id\": \"2eb7503f1b771110636e0fe0604bcb06\"\n      }\n    ]\n  } \n}\n```\n\n## CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}\n\nReturns the current status of the specified configuration data upload request.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/upload-status/{upload_id}`\n\nDefault URL: `/api/sn_cdm/applications/upload-status/{upload_id}`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr><tr><td>\n\nupload\\_id\n\n</td><td>\n\nSys\\_id of the upload request whose status to return. This value is returned by the various CdmApplications upload request endpoints.\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Header|Description|\n|------|-----------|\n|Accept|Data format of the response body. Only supports **application/json**.|\n\n|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Status code|Description|\n|-----------|-----------|\n|200|Successful. The request was successfully processed.|\n|400|Bad Request. A bad request type or malformed request was detected.|\n|500|Internal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.|\n\n### Response body parameters \\(JSON or XML\\)\n\n<table><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nerrors\n\n</td><td>\n\nDescription of the error\\(s\\) encountered during upload.Data type: String\n\n</td></tr><tr><td>\n\noutput\n\n</td><td>\n\nDescription of the uploaded data or if an error occurred during the upload, an error message describing the error that was encountered.Data type: Array of String\n\n```\n\"output\": {\n  \"auto_validate\": \"String\",\n  \"cdm_application\": \"String\",\n  \"committed_at\": \"String\",\n  \"committed_by\": \"String\",\n  \"description\": \"String\",\n  \"last_conflict_detection_time\": \"String\",\n  \"number\": \"String\",\n  \"publish_option\": \"String\",\n  \"snapshot_description\": \"String\",\n  \"snapshot_name\": \"String\",\n  \"state\": \"String\",\n  \"sys_created_by\": \"String\",\n  \"sys_id\": \"String\",\n  \"title\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\noutput.auto\\_validate\n\n</td><td>\n\nIndicates whether to invoke validation after the commit.Data type: String\n\n</td></tr><tr><td>\n\noutput.cdm\\_application\n\n</td><td>\n\nName of application under which the upload was performed.Data type: String\n\n</td></tr><tr><td>\n\noutput.committed\\_at\n\n</td><td>\n\nDate and time that the uploaded content was committed.Data type: String\n\n</td></tr><tr><td>\n\noutput.committed\\_by\n\n</td><td>\n\nSys\\_id of the record of the entity that performed the commit.Data type: String\n\n</td></tr><tr><td>\n\noutput.description\n\n</td><td>\n\nNot currently used.Data type: String\n\n</td></tr><tr><td>\n\noutput.last\\_conflict\\_detection\\_time\n\n</td><td>\n\nDate and time conflict detection invocation.Data type: String\n\n</td></tr><tr><td>\n\noutput.number\n\n</td><td>\n\nUnique number of the changeset.Data type: String\n\n</td></tr><tr><td>\n\noutput.publish\\_option\n\n</td><td>\n\nPublish option for the associated configured snapshots.\n\nValid values:\n\n-   publish\\_none: Don't publish any snapshots.\n-   publish\\_valid: Publish only those snapshots that pass validation after the commit.\n\nFor additional information on publishing snapshots, see [Publish or unpublish a snapshot](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-snapshot-publish.md).\n\nData type: String\n\nDefault: publish\\_none\n\n **Note:** This option is only available if the value for the **autoCommit** parameter is true.\n\n</td></tr><tr><td>\n\noutput.snapshot\\_description\n\n</td><td>\n\nDescription of the associated snapshot.Data type: String\n\n</td></tr><tr><td>\n\noutput.snapshot\\_name\n\n</td><td>\n\nName of the associated snapshot.Data type: String\n\n</td></tr><tr><td>\n\noutput.state\n\n</td><td>\n\nState of the upload content.Possible values:\n\n-   blocked\n-   checking\\_for\\_conflict\n-   commit\\_failed\n-   commit\\_in\\_progress\n-   committed\n-   open\n\nData type: String\n\n</td></tr><tr><td>\n\noutput.sys\\_created\\_by\n\n</td><td>\n\nSys\\_id of the entity that created the record.Data type: String\n\n</td></tr><tr><td>\n\noutput.sys\\_id\n\n</td><td>\n\nSys\\_id of the record containing the changeset.Data type: String\n\n</td></tr><tr><td>\n\noutput.title\n\n</td><td>\n\nTitle of changeset created as part of the upload.Data type: String\n\n</td></tr><tr><td>\n\nprocessing\\_state\n\n</td><td>\n\nCurrent processing state of the upload request.Possible values:\n\n-   NOT\\_PROCESSED\n-   PROCESSED\n\nData type: String\n\n</td></tr><tr><td>\n\nstate\n\n</td><td>\n\nCurrent state of the upload request.Possible values:\n\n-   completed\n-   error\n-   in\\_progress\n-   new\n-   ready\n\n</td></tr><tr><td>\n\ntype\n\n</td><td>\n\nType of upload request.Possible values:\n\n-   commit\n-   upload\\_and\\_commit\n\nData type: String\n\n</td></tr><tr><td>\n\nupload\\_id\n\n</td><td>\n\nSys\\_id of the upload request. Use this ID to call the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to obtain the status of the upload.Data type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following example show requesting the status for an upload with the ID of 5560a6895326301096edddeeff7b1230.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/upload-status/5560a6895326301096edddeeff7b1230\" \\ \n--request GET \\ \n--header \"Accept:application/json\" \\\n--user 'username':'password' \n```\n\nThe following are the possible return results.\n\n```\n// Successful completion of the upload request\n{ \n  \"result\": { \n    \"type\": \"upload_and_commit\", \n    \"state\": \"completed\", \n    \"output\": { \n      \"sys_id\": \"be681dc95362301096edddeeff7b12ba\", \n      \"number\": \"Chset-102\", \n      \"title\": \"admin2021-09-10 08:09:07\", \n      \"description\": null, \n      \"committed_at\": \"2021-09-10 20:23:37\", \n      \"committed_by\": \"6816f79cc0a8016401c5a33be04be441\", \n      \"sys_created_by\": \"admin\", \n      \"state\": \"committed\", \n      \"publish_option\": \"publish_none\", \n      \"auto_validate\": false, \n      \"snapshot_name\": null, \n      \"snapshot_description\": null, \n      \"cdm_application\": \"Demo_App1631126164773\", \n      \"last_conflict_detection_time\": \"1631305417894\" \n    }, \n    \"processing_state\": \"PROCESSED\", \n    \"upload_id\": \"5560a6895326301096edddeeff7b1230\"\n  } \n}\n\n// Response when an incorrect upload_id is passed. Note: Status code is 200.\n{ \n  \"result\": { \n    \"state\": \"error\", \n    \"errors\": \"Invalid requestId '5560a6895326301096edddeeff7b1240'\", \n    \"upload_id\": \"5560a6895326301096edddeeff7b1240\" \n  } \n} \n\n// Response when the upload encounters an error. The exporter_result array contains the error information. Note: Status code is 200.\n{ \n  \"result\": { \n    \"type\": \"upload_and_commit\", \n    \"state\": \"error\", \n    \"output\": \"Error encountered during execution of request.\\nError: Node 'dbSettings' of type 'sg_cdm_node_component' cannot create child 'dbSettings' of type 'sg_cdm_node_folder'\", \n    \"processing_state\": \"PROCESSED\", \n    \"upload_id\": \"272f8a415326301096edddeeff7b1232\" \n  } \n}\n```\n\n## CdmApplicationsApi - POST /sn\\_cdm/applications/deployables\n\nCreates a new deployable and automatically connects it to a specified Configuration Data Management \\(CDM\\) application.\n\nYou can create a deployable for any one of three environment types: Development, Test, or Production.\n\nTo access this endpoint the caller must have the CDM Admin role.\n\nIf you need to create multiple deployables, use the [CdmApplicationsApi - POST /sn\\_cdm/applications/deployables/create](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint.\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/deployables`\n\nDefault URL: `/api/sn_cdm/applications/deployables`\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappName\n\n</td><td>\n\nRequired. Name of an existing, active CDM application to associate with the deployable.Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr><tr><td>\n\nenvType\n\n</td><td id=\"cdm_apps-envType-entry\">\n\nRequired. Environment type for the deployable.\n\nValid values \\(case-sensitive\\):\n\n-   Development\n-   Production\n-   Test\n\n**Note:** The deployable environment type can't be changed after creation.\n\nData type: String\n\n</td></tr><tr><td>\n\nname\n\n</td><td>\n\nRequired. Name of the CDM deployable.Should not be more than 255 chars. Default allowed characters are 0-9, A-Z, a-z, \\_,-,., %, $, whitespace, :, \\#.\n\n Data type: String\n\n Maximum length: 255 characters\n\n Allowable characters: 0-9, A-Z, a-z, \\_, -, ., %, $, whitespace, :, and \\#\n\n</td></tr><tr><td>\n\nreturnFields\n\n</td><td id=\"cdm_apps-returnFields-entry\">\n\nList of fields to return as part of the response. Pass the record column names such as sys\\_id, sys\\_updated\\_by, or state.Data type: Array\n\nDefault: All fields as determined by the endpoint\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Header|Description|\n|------|-----------|\n|Accept|Data format of the response body. Only supports **application/json**.|\n|Content-Type|Data format of the request body. Only supports **application/json**.|\n\n|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Status code|Description|\n|-----------|-----------|\n|200|Successful. The request was successfully processed.|\n|400|Bad Request. A bad request type or malformed request was detected.|\n|500|Internal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.|\n\n### Response body parameters\n\n<table id=\"id_dkr_tdn_qtb\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\ncdi\\_count\n\n</td><td>\n\nNumber of configuration data items \\(CDIs\\) contained in the associated CDM application.Data type: Number \\(Integer\\)\n\n</td></tr><tr><td>\n\ncdi\\_usage\n\n</td><td>\n\nPercentage of the CDIs used by the deployable.Data type: Number \\(Integer\\)\n\n</td></tr><tr><td>\n\ncdm\\_app\n\n</td><td>\n\nCDM application object associated with the deployable.Data type: Object\n\n```\n\"cdm_app\": {\n  \"link\": \"String\",\n  \"value\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\ncdm\\_app.link\n\n</td><td id=\"cdm_app_link-app-entry\">\n\nCall to use to access the CDM application record using the REST Table API. Data type: String\n\n</td></tr><tr><td>\n\ncdm\\_app.value\n\n</td><td id=\"cdm_app_value-app-entry\">\n\nSys\\_id of the associated CDM application record.Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr><tr><td>\n\ncdm\\_ci\n\n</td><td>\n\nApplication service object associated with the deployable.Data type: Object\n\n```\n\"cdm_ci\": {\n  \"link\": \"String\",\n  \"value\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\ncdm\\_ci.link\n\n</td><td>\n\nCall to use to access the application service record using the REST Table API.Data type: String\n\n</td></tr><tr><td>\n\ncdm\\_ci.value\n\n</td><td>\n\nSys\\_id of the associated application service record. Data type: String\n\nTable: Configuration Item \\[cmdb\\_ci\\]\n\n</td></tr><tr><td>\n\ndescription\n\n</td><td>\n\nDescription of the generated CDM deployable.Data type: String\n\n</td></tr><tr><td>\n\nenvironment\\_type\n\n</td><td>\n\nEnvironment type of the deployable.Possible values:\n\n-   Development\n-   Production\n-   Test\n\nData type: String\n\n</td></tr><tr><td>\n\nerror\n\n</td><td id=\"cdm_apps-error-entry\">\n\nOnly returned if an error occurred during processing.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr><td>\n\nname\n\n</td><td>\n\nName of the CDM deployable.Data type: String\n\n</td></tr><tr><td>\n\nnode\n\n</td><td>\n\nDetails about the deployable node.Data type: Object\n\n```\n\"node\": {\n  \"link\": \"String\",\n  \"value\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\nnode.link\n\n</td><td>\n\nCall to use to access the deployable node record using the REST Table API. Data type: String\n\n</td></tr><tr><td>\n\nnode.value\n\n</td><td>\n\nSys\\_id of the deployable node record.Data type: String\n\nTable: CDM Deployable \\[sn\\_cdm\\_deployable\\]\n\n</td></tr><tr><td>\n\nsnapshot\\_version\\_counter\n\n</td><td>\n\nNumber of snapshots created for the deployable.Data type: Number \\(Integer\\)\n\n</td></tr><tr><td>\n\nstate\n\n</td><td>\n\nCurrent state of the deployable.Possible values:\n\n-   active\n-   deleted\n\nData type: String\n\n</td></tr><tr id=\"cdm_dep-sys_created_by-row\"><td>\n\nsys\\_created\\_by\n\n</td><td>\n\nUser name of the user that created the CDM deployable. For example, able.tuter.Data type: String\n\n</td></tr><tr id=\"cdm_deps-sys_created_on-row\"><td>\n\nsys\\_created\\_on\n\n</td><td>\n\nDate and time when the CDM deployable was created.Data type: String\n\nFormat: YYYY-mm-DD hh:mm:ss\n\n</td></tr><tr><td>\n\nsys\\_id\n\n</td><td>\n\nSys\\_id of the created deployable.Data type: String\n\nTable: CDM Deployable \\[sn\\_cdm\\_deployable\\]\n\n</td></tr><tr id=\"cdm_dep-sys_updated_by-row\"><td>\n\nsys\\_updated\\_by\n\n</td><td>\n\nUser name of the user that last updated the CDM deployable. For example, able.tuter.Data type: String\n\n</td></tr><tr id=\"cdm_dep-sys_updated_on-row\"><td>\n\nsys\\_updated\\_on\n\n</td><td>\n\nDate and time when the CDM deployable was last updated.Data type: String\n\nFormat: YYYY-mm-DD hh:mm:ss\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following code example shows how to create and associate a deployable to a CDM application.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/deployables?name=Dep-1&returnFields=name%2Csys_id%2Cstate&appName=testApp&envType=Test\" \\ \n--request POST \\ \n--header \"Accept:application/json\" \\ \n--user 'username':'password1' \n```\n\nReturn results:\n\n```\n{ \n  \"result\": [ \n    { \n      \"cmdb_ci\": { \n        \"value\": \"f5b9e00b53901110a1d3ddeeff7b12b8\", \n        \"link\": \"http://192.168.0.233:8080/api/now/table/cmdb_ci_service_auto/f5b9e00b53901110a1d3ddeeff7b12b8\" \n      }, \n      \"cdi_count\": \"0\", \n      \"snapshot_version_counter\": \"0\", \n      \"description\": null, \n      \"sys_updated_on\": \"2022-06-29 12:53:57\", \n      \"environment_type\": \"Test\", \n      \"node\": { \n        \"value\": \"7db9e00b53901110a1d3ddeeff7b12b6\", \n        \"link\": \"http://192.168.0.233:8080/api/now/table/sn_cdm_node/7db9e00b53901110a1d3ddeeff7b12b6\" \n      }, \n      \"sys_id\": \"39b9e00b53901110a1d3ddeeff7b12b7\", \n      \"sys_updated_by\": \"admin\", \n      \"cdm_app\": { \n        \"value\": \"62b517a953b70110a1d3ddeeff7b128c\", \n        \"link\": \"http://192.168.0.233:8080/api/now/table/sn_cdm_application/62b517a953b70110a1d3ddeeff7b128c\" \n      }, \n      \"sys_created_on\": \"2022-06-29 12:53:57\", \n      \"cdi_usage\": \"0\", \n      \"name\": \"Dep-2\", \n      \"state\": \"active\", \n      \"sys_created_by\": \"admin\" \n    } \n  ] \n}\n```\n\n## CdmApplicationsApi - POST /sn\\_cdm/applications/deployables/create\n\nCreates one or more new deployables.\n\nYou can create one of two types of deployables:\n\n-   Deployables that must be manually connected to an Application Model \\(CI Service\\).\n-   Deployables that are automatically connected to new, dynamically created Application Models \\(CI Services\\).\n\nYou can create a deployable for any one of three environment types: Development, Test, or Production. When creating multiple deployables, the auto-generated names of the deployables follow the pattern: `DeployableType_Number`, where `Number` is a running sequence number based on the creation of a new deployable. For example, if you create three deployables of type `Test` in an endpoint call, they are named Test\\_1, Test\\_2, and Test\\_3. If you then call the endpoint again, and create a different Test deployable, its auto-gen'd name is Test\\_4. These numbers are never reused, even if a deployable is deleted.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/deployables/create`\n\nDefault URL: `/api/sn_cdm/applications/deployables/create`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappSysId\n\n</td><td>\n\nRequired. Sys\\_id of an active CDM Application to associate with the deployables.Data type: String\n\n</td></tr><tr><td>\n\nautoConnect\n\n</td><td>\n\nRequired. Flag that determines whether to automatically connect the newly created deployables to dynamically generated Application Models.Valid values:\n\n-   true: Connect the newly created deployables to dynamically generated Application Models.\n-   false: Just create the deployables. These deployables must be manually mapped to Application Models using the UI.\n\n Data type: Boolean\n\n</td></tr><tr><td>\n\nenvType\n\n</td><td id=\"cdm_apps-envType-entry\">\n\nRequired. Environment type for the deployable.\n\nValid values \\(case-sensitive\\):\n\n-   Development\n-   Production\n-   Test\n\n**Note:** The deployable environment type can't be changed after creation.\n\nData type: String\n\n</td></tr><tr><td>\n\nquantity\n\n</td><td>\n\nRequired. Number of deployables to create.Data type: Number\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Header|Description|\n|------|-----------|\n|Accept|Data format of the response body. Only supports **application/json**.|\n|Content-Type|Data format of the request body. Only supports **application/json**.|\n\n|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Status code|Description|\n|-----------|-----------|\n|200|Successful. The request was successfully processed.|\n|500|Internal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.|\n\n### Response body parameters\n\n<table><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nerror\n\n</td><td>\n\nIf an error occurred during processing, the details about the error.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr><td>\n\nresult\n\n</td><td>\n\nSys\\_ids of the created deployables.Data type: Array\n\n</td></tr><tr><td>\n\nstatus\n\n</td><td>\n\nError status of the request.Possible values: failure\n\nData type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following example shows how to create a single deployable and associate it with and existing CDM application.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/deployables/create?envType=Production&appSysId=5e118055b712011054c1e5a6ce11a9d4&quantity=5&autoConnect=true\" \\ \n--request POST \\ \n--header \"Accept:application/json\" \\ \n--header \"Content-Type:application/json\" \\\n--user 'username':'password' \n```\n\nThe following shows the possible responses to this call, both as a success and an error.\n\n```\n// Successful completion of the upload request\n{\n  \"result\": [\n    \"8ba43a3db7d6011054c1e5a6ce11a9a4\",\n    \"93a47a3db7d6011054c1e5a6ce11a90d\",\n    \"dba47a3db7d6011054c1e5a6ce11a91d\",\n    \"6fa47a3db7d6011054c1e5a6ce11a921\",\n    \"efa47a3db7d6011054c1e5a6ce11a925\"\n  ]\n} \n\n// Error response\n{\n  \"error\": {\n    \"message\": \"Error: CDM Application with SysID 5e118055b712011054c1e5a6ce11a9d1 was not found. (sys_script_include.8cf0fbf453626010a1d3ddeeff7b12fe.script; line 211)\",\n    \"detail\": \"\"\n  },\n  \"status\": \"failure\"\n}\n```\n\n## CdmApplicationsApi - POST /sn\\_cdm/applications/deployables/exports\n\nSubmits a request to export the current snapshot for a specified application and one or more deployables into the CDM Exporter Cache \\[sn\\_cdm\\_exporter\\_cache\\] table.\n\nThis endpoint returns a unique identifier for the request, which you then use to call the [CdmApplicationsApi - GET /sn\\_cdm/applications/deployables/exports/\\{export\\_id\\}/status](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to retrieve the status of the export. Once the export is complete, you can use the [CdmApplicationsApi - GET /sn\\_cdm/applications/deployables/exports/\\{export\\_id\\}/content](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to retrieve the associated application's configuration data.\n\nA snapshot is the complete data model of a deployable at the time a configuration change is committed. This includes any included components, collections, and vars, as well as deployable-specific vars and overrides. For additional information on deployables, see [Create and update a deployable](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-deployable-define.md).\n\n**Note:** Snapshots cannot exceed 10,000 configuration data items \\(CDIs\\) per deployable or 100,000 CDIs per application.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/deployables/exports`\n\nDefault URL: `/api/sn_cdm/applications/deployables/exports`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nadditionalDeployables\n\n</td><td>\n\nNon-primary deployables to export.Data type: Array of Objects\n\n```\n\"additionalDeployables\": [\n  {\n    \"app_name\": \"String\",\n    \"deployable_name\": \"String\"\n  }\n]\n```\n\nFor example: `[{'app_name':'TestApp', \"deployable_name:'DEP-1'}]`\n\nDefault: Empty array - \\[\\]\n\n</td></tr><tr><td>\n\nadditionalDeployables.app\\_name\n\n</td><td>\n\nRequired if **additionalDeployables** array is specified. Name of the application associated with the deployable whose configuration data you want to export.Data type: String\n\n</td></tr><tr><td>\n\nadditionalDeployables.deployable\\_name\n\n</td><td>\n\nRequired if **additionalDeployables** array is specified. Name of the non-primary deployable whose configuration data you want to export.Data type: String\n\n</td></tr><tr><td>\n\nappName\n\n</td><td>\n\nRequired. Name of the application whose configuration data you want to export.Data type: String\n\n</td></tr><tr><td>\n\nargs\n\n</td><td>\n\nA JSON object containing key-value pairs for custom arguments.Data type: Object\n\n</td></tr><tr><td>\n\ndataFormat\n\n</td><td>\n\nOutput format of the exported data.Valid values \\(case-sensitive\\):\n\n-   ini\n-   json\n-   properties\n-   raw \\(Data is returned in String format\\)\n-   xml\n-   yaml\n\nData type: String\n\nDefault: json\n\n</td></tr><tr><td>\n\ndeployableName\n\n</td><td>\n\nRequired. Name of the deployable whose configuration data you want to export.Data type: String\n\n</td></tr><tr><td>\n\nexporterName\n\n</td><td>\n\nRequired. Name of the exporter to use to export the snapshot data. Exporters are custom to the implementer. For details on creating a custom exporter, see [Create a custom exporter](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-exporter-create-custom.md).Data type: String\n\n</td></tr><tr><td>\n\nrestrictExport\n\n</td><td>\n\nFlag that indicates whether the endpoint validates snapshots when exporting the data.Valid values:\n\n-   true: Validate snapshots.\n-   false: Don't validate snapshots.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nsnapshotName\n\n</td><td>\n\nName of the snapshot to export. This can only be one of the snapshot names associated with the deployable as specified in the **deployableName** or **additionalDeployables.deployable\\_name** parameters. Default: The endpoint exports the latest published snapshot. If there is not a published snapshot, the system throws the error “Failed to find latest published snapshot for deployable '\\{0\\}'”\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Header|Description|\n|------|-----------|\n|Accept|Data format of the response body. Only supports **application/json**.|\n|Content-Type|Data format of the request body. Only supports **application/json**.|\n\n|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table><thead><tr><th>\n\nStatus code\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\n200\n\n</td><td id=\"entry-200-status-code\">\n\nSuccessful. The request was successfully processed.\n\n</td></tr><tr><td>\n\n400\n\n</td><td>\n\nBad Request. A bad request type or malformed request was detected.Possible error messages:\n\n-   Error: Missing required param 'appName'\n-   Error: User does not have necessary permission to create Export request\n-   Error: Invalid Boolean value \\(&lt;xyz&gt;\\).\n\n</td></tr><tr><td>\n\n500\n\n</td><td id=\"entry-500-status-code\">\n\nInternal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.\n\n</td></tr></tbody>\n</table>### Response body parameters\n\n<table><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr id=\"cdm_apps-stat-error\"><td>\n\nerror\n\n</td><td>\n\nDetails about the error that occurred.Data type: Array\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr id=\"cdm_apps-stat-error_detail-row\"><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_messaage-row\"><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr><td>\n\nexport\\_id\n\n</td><td>\n\nUnique identifier of the export request. Use this ID when calling the [CdmApplicationsApi - GET /sn\\_cdm/applications/deployables/exports/\\{export\\_id\\}/status](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to check the current status of the export request.Data type: String\n\n</td></tr><tr><td>\n\nstatus\n\n</td><td>\n\nError status of the request.Possible values: failure\n\nData type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following example requests the export of the configuration data for the following: application name = TestAppA, deployable name = DEP, using the exporter = exporter-1-primary\\_deployable.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/deployables/exports?appName=TestAppA&args=%7B%22arg_A_required%22%20%3A%20%22value%20A%22%7D&exporterName=exporter-1-primary_deployable&deployableName=DEP1\" \\ \n--request POST \\ \n--header \"Accept:application/json\" \\ \n--header \"Content-Type:application/json\" \\\n--user 'username':'password' \n```\n\nReturns the unique identifier of the export request.\n\n```\n{ \n  \"result\": {\n    \"export_id\": \"64b5f79f5379301096edddeeff7b12eb\" \n  } \n}\n```\n\n## CdmApplicationsApi - POST /sn\\_cdm/applications/shared\\_components\n\nAssociates the specified shared component to the application within a specified changeset.\n\nThe CDM Admin role is required to access this endpoint.\n\n**Note:** The specified shared component must have an associated published version \\(snapshot\\).\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/shared_components`\n\nDefault URL: `/api/sn_cdm/applications/shared_components`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappName\n\n</td><td>\n\nRequired. Name of the application to associate with the shared component.Data type: String\n\n</td></tr><tr><td>\n\nchangesetNumber\n\n</td><td>\n\nRequired. Unique identifier of the changeset associated with the component.Data type: String\n\n</td></tr><tr><td>\n\nreturnFields\n\n</td><td id=\"cdm_apps-returnFields-entry\">\n\nList of fields to return as part of the response. Pass the record column names such as sys\\_id, sys\\_updated\\_by, or state.Data type: Array\n\nDefault: All fields as determined by the endpoint\n\n</td></tr><tr><td>\n\nsharedComponentName\n\n</td><td>\n\nRequired. Name of the shared component to associate with the specified application.Data type: String\n\nTable: CDM Shared Component \\[sn\\_cdm\\_shared\\_component\\]\n\n</td></tr><tr><td>\n\nsharedLibraryName\n\n</td><td>\n\nRequired. Name of the shared library under which to create the component. The shared library must have the following fields defined as follows:-   state = active\n-   available = true\n-   type = shared\\_library\n\nData type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table class=\"rest_api_request_headers\"><thead><tr><th>\n\nHeader\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nAccept\n\n</td><td id=\"accept-entry-RESTAPI\">\n\nData format of the response body. Supported types: **application/json** or **application/xml**. Default: **application/json**\n\n</td></tr></tbody>\n</table>|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Status code|Description|\n|-----------|-----------|\n|200|Successful. The request was successfully processed.|\n|400|Bad Request. The passed changeset doesn't exist.|\n|500|Internal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.|\n\n### Response body parameters\n\nThe response fields depend on what fields were specified in the **returnFields** parameter in the request. The following describes some of the more important fields.\n\n<table><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nchangeset\\_id\n\n</td><td id=\"changeset-node-editor-entry\">\n\nDetails of the changeset record associated with the node. Data type: Object\n\n```\n\"changeset_id\": {\n  \"link\": \"String\",\n  \"value\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\nchangeset\\_id.link\n\n</td><td id=\"changeset_link-node-editor-entry\">\n\nCall syntax for querying this changeset record using the Table REST API.Data type: String\n\n</td></tr><tr><td>\n\nchangeset\\_id.value\n\n</td><td id=\"changeset_value-node-editor-entry\">\n\nUnique identifier of the changeset record.Data type: String\n\nTable: CDM Changeset \\[sn\\_cdm\\_changeset\\]\n\n</td></tr><tr><td>\n\ndescription\n\n</td><td>\n\nDescription of the CDM node.Data type: String\n\n</td></tr><tr><td>\n\nerror\n\n</td><td id=\"cdm_apps-error-entry\">\n\nOnly returned if an error occurred during processing.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\nerror.detail\n\n</td><td id=\"cdm_apps-error_detail-entry\">\n\nDetails about the error that occurred.Data type: String\n\n</td></tr><tr><td>\n\nerror.message\n\n</td><td id=\"cdm_apps-error_message-entry\">\n\nMessage that provides an overview of the error.Data type: String\n\n</td></tr><tr><td>\n\nlinked\\_to\n\n</td><td>\n\nID of the main node associated with the shared component.Data type: String\n\n</td></tr><tr><td>\n\nlinked\\_to\\_version\n\n</td><td>\n\nDetails of the CDM snapshot record associated with the node. Data type: Object\n\n```\n\"linked_to_version\": {\n  \"link\": \"String\",\n  \"value\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\nlinked\\_to\\_version.link\n\n</td><td>\n\nCall syntax for querying this version record using the Table REST API.Data type: String\n\n</td></tr><tr><td>\n\nlinked\\_to\\_version.value\n\n</td><td>\n\nSys\\_id of the version record.Data type: String\n\n</td></tr><tr><td>\n\nmain\n\n</td><td>\n\nFlag that indicates whether the associated snapshot was published.\n\n Valid values:\n\n-   true: Snapshot was published.\n-   false: Snapshot wasn't published.\n\n</td></tr><tr><td>\n\nmain\\_id\n\n</td><td>\n\nUnique ID of the newly created main node.Data type: String\n\n</td></tr><tr><td>\n\nmain\\_id\\_encoded\n\n</td><td>\n\nEncoded ID of the newly created main node.Data type: String\n\n</td></tr><tr><td>\n\nname\n\n</td><td>\n\nName of the CDM node.Data type: String\n\n</td></tr><tr><td>\n\nnode\n\n</td><td>\n\nSys\\_id of the shared component node.Data type: String\n\n</td></tr><tr><td>\n\nnode\\_path\n\n</td><td>\n\nPath to the new linked node created when adding the shared component. Data type: String\n\n</td></tr><tr><td>\n\nstatus\n\n</td><td>\n\nStatus of the node.Possible values: New\n\nData type: String\n\n</td></tr><tr id=\"cdm_dep-sys_created_by-row\"><td>\n\nsys\\_created\\_by\n\n</td><td>\n\nUser name of the user that create the CDM node. For example, able.tuter.Data type: String\n\n</td></tr><tr id=\"cdm_deps-sys_created_on-row\"><td>\n\nsys\\_created\\_on\n\n</td><td>\n\nDate and time when the CDM node was created.Format: YYYY-mm-DD hh:mm:ss\n\nData type: String\n\n</td></tr><tr><td>\n\nsys\\_id\n\n</td><td id=\"sys_id-node-editor-entry\">\n\nSys\\_id of the node.Data type: String\n\nTable: CDM Node \\[sn\\_cdm\\_node\\]\n\n</td></tr><tr id=\"cdm_dep-sys_updated_by-row\"><td>\n\nsys\\_updated\\_by\n\n</td><td>\n\nUser name of the user that last updated the CDM node. For example, able.tuter.Data type: String\n\n</td></tr><tr id=\"cdm_dep-sys_updated_on-row\"><td>\n\nsys\\_updated\\_on\n\n</td><td>\n\nDate and time when the CDM node was last updated.Format: YYYY-mm-DD hh:mm:ss\n\nData type: String\n\n</td></tr><tr><td>\n\ntype\n\n</td><td>\n\nNode type.Data type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following example shows how to call this endpoint to associate the application \"App1\" with the shared component \"paymentService-V1.1\" under the shared library \"OracleG-Library-10\" within the \"Chset-20\" changeset.\n\n```\ncurl \"https://instance.servicenow.com/api/sn_cdm/applications/shared_components?appName=App1&changesetNumber=Chset-20&sharedLibraryName=OracleG-Library-10&sharedComponentName=paymentService-V1.1\" \\ \n--request POST \\ \n--header \"Accept:application/json\" \\ \n--user 'username':'password'\n```\n\nResponse:\n\n```\n{ \n  \"result\": { \n    \"changeset_id\": { \n      \"value\": \"74b7ff6fc33711100c257e2cc840dd6b\", \n      \"link\": \"http://instance.servicenow.com/api/now/table/sn_cdm_changeset/74b7ff6fc33711100c257e2cc840dd6b\" \n    }, \n    \"node_path\": \"!,0!,1!/D\", \n    \"description\": null, \n    \"sys_updated_on\": \"2022-12-22 17:07:29\", \n    \"type\": \"sn_cdm_node_linked_shared_component\", \n    \"sys_class_name\": \"sn_cdm_node\", \n    \"sys_id\": \"ff8b37ebc3b711100c257e2cc840ddba\", \n    \"sys_updated_by\": \"admin\", \n    \"previous_version\": null, \n    \"sys_created_on\": \"2022-12-22 17:07:29\", \n    \"value\": null, \n    \"effective_from\": null, \n    \"linked_to\": \"210\", \n    \"sys_created_by\": \"admin\", \n    \"restricted_to\": null, \n    \"linked_to_version\": { \n      \"value\": \"581fc3e9c3b311100c257e2cc840dd17\", \n      \"link\": \"http://instance.servicenow.com/api/now/table/sn_cdm_snapshot/581fc3e9c3b311100c257e2cc840dd17\" \n    }, \n    \"level\": \"2\", \n    \"conflict_type\": null, \n    \"main_id\": \"483\",\n    \"effective_to\": null,\n    \"secure_value\": null, \n    \"node_classifier\": \"/application/components\", \n    \"main_id_encoded\": \"/D\",\n    \"name\": \"LIB2_C\",\n    \"position\": null,\n    \"reason_for_conflict\": null,\n    \"system_folder\": false,\n    \"status\": \"new\",\n    \"conflict\": false\n  } \n}\n```\n\n## CdmApplicationsApi - POST /sn\\_cdm/applications/uploads/components\n\nSubmits a request to upload the passed-in configuration data for a specific component, within the system components folder, for the specified application.\n\nThis endpoint returns the ID of the upload request. Use this ID to call the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to obtain the status of the upload.\n\n**Note:** The maximum default upload content size is 2 MB. You can modify this default by updating the property sn\\_cdm.max\\_allowed\\_upload\\_file\\_size.\n\nThe following image shows an example of where the component configuration data is uploaded in reference to the ServiceNow DevOps Config UI. Assumes the component is **dbComponent** and the application is **paymentSvc**.\n\n\\[Omitted image \"apps-uploads-components\\_data.png\"\\] Alt text: Example configuration content location within UI\n\n**Note:** This upload method cannot be used to modify nodes. Use the alternative [CdmApplicationsApi - POST sn\\_cdm/applications/uploads/components/file](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) method to modify nodes.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/uploads/components`\n\nDefault URL: `/api/sn_cdm/applications/uploads/components`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table id=\"id_plp_1vh_psb\" class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr id=\"cdm_apps-appName-row\"><td>\n\nappName\n\n</td><td>\n\nName of the application to associate with the configuration data. This application must be in the active state.Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr><tr id=\"cdm_apps-autoCommit-row\"><td>\n\nautoCommit\n\n</td><td>\n\nFlag that indicates whether the changeset identified in the **changesetNumber** parameter is committed to the data model after upload.Valid values:\n\n-   true: Changeset is committed after upload.\n-   false: Changeset isn't committed after upload.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr id=\"cdm_apps-autoDelete-row\"><td>\n\nautoDelete\n\n</td><td>\n\nFlag that indicates whether the existing nodes, that aren’t part of the upload content, are deleted after the processing is complete.Valid values:\n\n-   true: Automatically delete existing nodes.\n-   false: Don't automatically delete existing nodes.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr id=\"cdm_apps-autoValidate-row\"><td>\n\nautoValidate\n\n</td><td>\n\nFlag that indicates whether the snapshots created when committed are validated.Valid values:\n\n-   true: Validate the snapshots.\n-   false: Don't validate the snapshots.\n\n**Note:** This option is only available if the **autoCommit** parameter is `true`.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr id=\"cdm_apps-changesetNumber-row\"><td>\n\nchangesetNumber\n\n</td><td>\n\nString that uniquely identifies the [changeset](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-changesets-version-control.md) associated with the application, such as Chset-102. This changeset must be in the \"Open\" state.Data type: String\n\nDefault: Creates a changeset to use. The changeset details are returned as part of the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) results.\n\nTable: CDM Changeset \\[sn\\_cdm\\_changeset\\]\n\n</td></tr><tr id=\"cdm_apps-dataFormat-row\"><td>\n\ndataFormat\n\n</td><td>\n\nRequired. Format of the configuration data.Valid values:\n\n-   csv\n-   ini\n-   json\n-   properties\n-   raw\n-   xml\n-   yaml\n\nData type: String\n\n</td></tr><tr id=\"cdm_app-dataFormAtt-row\"><td>\n\ndataFormatAttributes\n\n</td><td id=\"cdm_app-dataFormAtt-entry\">\n\nOnly supported when the **dataFormat** parameter is set to `csv`. Attributes that define the CSV data format. For additional information, see [Parsing of CSV files in CDM](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-parsing-csv-file.md).Data type: Object\n\n```\n\"dataFormatAttributes\" {\n  \"containsHeader\": Boolean,\n  \"delimeter\": \"String\"\n  \"headers\": [Array],\n  \"securedHeaders\": [Array]\n}\n```\n\n</td></tr><tr id=\"cdm_app-dataFormAtt_containsHeaders-row\"><td>\n\ndataFormatAttributes.containsHeaders\n\n</td><td id=\"cdm_app-dataFormAtt_containsHeaders-entry\">\n\nFlag that indicates whether the data contains a header row.Valid values:\n\n-   true: Data contains a header row. The first row in the data is considered the header row.\n\n\\[Omitted image \"cdm\\_header\\_row\\_example.png\"\\] Alt text: Header row example\n\n-   false: Data doesn't contain a header row. You must pass the header information in the **dataFormatAttributes.headers** parameter.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr id=\"cdm_app-dataFormAtt_delimeter-row\"><td>\n\ndataFormatAttributes.delimeter\n\n</td><td id=\"cdm_app-dataFormAtt_delimeter-entry\">\n\nCharacter to use to delineate fields within the data.Data type: String\n\nDefault: Comma \",\"\n\n</td></tr><tr id=\"cdm_app-dataFormAtt_headers-row\"><td>\n\ndataFormatAttributes.headers\n\n</td><td id=\"cdm_app-dataFormAtt_headers-entry\">\n\nRequired if **dataFormatAttributes.containsHeaders** parameter is `false`. Fields in the data that comprise the header. These headers are converted to the key names of the CDIs in the JSON format. The number of headers must match the number of record fields.Data type: Array\n\nDefault: Empty array\n\n</td></tr><tr id=\"cdm_app-dataFormAtt_securedHeaders-row\"><td>\n\ndataFormatAttributes.securedHeaders\n\n</td><td id=\"cdm_app-dataFormAtt_securedHeaders-entry\">\n\nFields in the data that are secure fields and must be encrypted in the data uploaded to CDM. The name of the secured headers must match the name of the headers in the headers attribute or data file. These fields are stored in a column of type Password \\(2 Way Encrypted\\).**Note:** You can only secure fields using this attribute. You can't unsecure the secured fields.\n\nData type: Array\n\nDefault: Empty array\n\n</td></tr><tr id=\"cdm_apps-deleteRedundantOverrides-row\"><td>\n\ndeleteRedundantOverrides\n\n</td><td>\n\nFlag that indicates whether to create an override where redundant values are present.Valid values:\n\n-   true: If redundant values are present, an override isn’t created.\n-   false: If redundant values are present, proceeds with an override.\n\nDefault: true\n\n</td></tr><tr id=\"cdm_apps-fileName-row\"><td>\n\nfileName\n\n</td><td>\n\nName of the file to upload. This name can differ from than the actual file name and contain the file extension. For example, .txt/.scv/.jar. The fileName value is applied when downloading the file.Data type: String\n\n</td></tr><tr id=\"cdm_apps-fileNodeName-row\"><td>\n\nfileNodeName\n\n</td><td>\n\nName of the file node. This file name is used in the configuration data when exporting it. This name doesn’t require a file extension nor does it affect the download.Data type: String\n\n</td></tr><tr id=\"cdm_apps-identifierKeys-row\"><td>\n\nidentifierKeys\n\n</td><td>\n\nList of names that indicate which key in an array child to use to identify the same node.For example, if you’re uploading:\n\n```\n[\n  {\"name\" : \"Allan, \"city\" : \"Paris\"}, \n  {\"name\" : \"Karen, \"city\" : \"Sydney\"}\n]\n```\n\nin the following existing model:\n\n```\n[\n  {\"name\" : \"Karen, \"city\" : \"Manila\"},\n  {\"name\" : \"Allan, \"city\" : \"Brussels\"}\n]\n```\n\nand you set **identifierKeys** to `name`, it produces the following output:\n\n```\n[\n  {\"name\" : \"Karen, \"city\" : \"Sydney\"},\n  {\"name\" : \"Allan, \"city\" : \"Paris\"}\n]\n```\n\nOtherwise, it produces the following output:\n\n```\n[\n  {\"name\" : \"Karen, \"city\" : \"Manila\"},\n  {\"name\" : \"Allan, \"city\" : \"Brussels\"},\n  {\"name\" : \"Allan, \"city\" : \"Paris\"},\n  {\"name\" : \"Karen, \"city\" : \"Sydney\"}\n]\n```\n\nData type: Array of Strings\n\n</td></tr><tr id=\"cdm_apps-ignoreAttributes-row\"><td>\n\nignoreAttributes\n\n</td><td>\n\nFlag that indicates whether the given data format supports attributes \\(currently only XML\\).Valid values:\n\n-   true: If the given data format supports attributes, any attributes in the input data are skipped during the upload.\n-   false: If the given data format supports attributes, any attributes in the input data are included in the upload.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr id=\"cdm_apps-namePath-row\"><td>\n\nnamePath\n\n</td><td>\n\nPath of the targeted node under which the configuration data should be uploaded. This path is relative to the components, collection, or deployable folder \\(depending on the endpoint being called\\).You can pass the name path in any of the following formats. For example, to define the name path for the node `testApp/deployables/Development1/cdi1`:\n\n-   Backslash format: `testApp/deployables/Development1/cdi1`\n\n**Note:** If your node name contains a backslash \\(\"/\"\\), you can’t use this format.\n\n-   Backend name path with replacement characters: `testApp�deployables�​Development1​�​cdi1`\n-   Array: `['testApp','deployables','Development1','cdi1']`\n\n**Note:** If the specified component doesn't exist at the specified path, the system automatically creates the component at the specified path and then uploads the data.\n\nData type: String\n\n</td></tr><tr id=\"cdm_apps-sharedLibraryName-row\"><td>\n\nsharedLibraryName\n\n</td><td>\n\nRequired. Name of the shared library where the component to delete is located.Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|Variable upload data|Configuration data to upload. This can be any data in the format defined by the **dataFormat** parameter of the query parameters.|\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table id=\"id_trg_k25_2wb\" class=\"rest_api_request_headers\"><thead><tr><th>\n\nHeader\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nAccept\n\n</td><td id=\"accept-JSON-only-entry-RESTAPI\">\n\nData format of the response body. Only supports **application/json**.\n\n</td></tr><tr><td>\n\nContent-Type\n\n</td><td>\n\nData format of the request body. Supported types: **text/plain** and **application/x-www-form-urlencoded**.Default: **text/plain**\n\n</td></tr></tbody>\n</table>|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table id=\"id_vvq_4wh_psb\"><thead><tr><th>\n\nStatus code\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\n200\n\n</td><td id=\"entry-200-status-code\">\n\nSuccessful. The request was successfully processed.\n\n</td></tr><tr><td>\n\n400\n\n</td><td>\n\nBad request.Upload request has been rejected.\n\nPossible issues:\n\n-   Size of configuration payload is greater that the allowed maximum - 2 MB by default.\n-   Required parameters are missing from the call.\n\n</td></tr><tr><td>\n\n500\n\n</td><td id=\"entry-500-status-code\">\n\nInternal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.\n\n</td></tr></tbody>\n</table>### Response body parameters \\(JSON or XML\\)\n\n<table id=\"id_b4z_nwh_psb\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr id=\"cdm_apps-stat-error\"><td>\n\nerror\n\n</td><td>\n\nIf an error occurred during processing, the details about the error.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr id=\"cdm_apps-stat-error_detail-row\"><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_messaage-row\"><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_status-row\"><td>\n\nstatus\n\n</td><td>\n\nError status of the request.Possible values: failure\n\nData type: String\n\n</td></tr><tr id=\"cdm_apps-upload_id-row\"><td>\n\nupload\\_id\n\n</td><td>\n\nSys\\_id of the upload request. Use this ID to call the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to obtain the status of the upload.Data type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following example shows an upload request for the application Demo\\_App1631126164773.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/uploads/components?namePath=%2FSettings%2FdbSettings&dataFormat=json&appName=Demo_App1631126164773&changesetNumber=Chset-8&autoCommit=false&publishOption=publish_none&autoValidate=false&autoDelete=true\" \\ \n--request POST \\ \n--header \"Accept:application/json\" \\ \n--header \"Content-Type:text/plain\" \\ \n--data \"{\n  \\\"dbIPAddress\\\": \\\"10.10.10.110\\\",\n  \\\"dbPort\\\": \\\"8080\\\",\n  \\\"dbConnectionString\\\": \\\"admin:admin server1.xyz.com:8080 dbName_payments\\\",\n  \\\"dbConnectionStringBackup\\\": \\\"admin:admin server2.xyz.com dbName_payments_backup\\\n\"}\" \\ \n--user 'username':'password' \n```\n\nThe following return results show both a successful and an error response for this request.\n\n```\n// Successful completion of the upload request\n{ \n  \"result\": { \n    \"upload_id\": \"ec1f71f45322301096edddeeff7b12b3\" \n  } \n} \n\n// Error response. Payload is too large.\n{ \n  \"error\": { \n    \"message\": \"Size of uploaded data:6853632.0(bytes) is greater than max allowed upload limit of 2097152.0(bytes)\", \n    \"detail\": \"\" \n  },\n  \"status\": \"failure\"\n}\n```\n\n## CdmApplicationsApi - POST sn\\_cdm/applications/uploads/components/file\n\nUploads files as part of the Configuration Data Model \\(CDM\\) to the components folder.\n\nUse this method to upload to a components file node.\n\n### URL format\n\nVersioned URL: `POST /api/sn_cdm/{api_version}/applications/uploads/components/file`\n\nDefault URL: `POST /api/sn_cdm/applications/uploads/components/file`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table id=\"table_rgl_tbt_byb\" class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table id=\"cdm_app-upload_query_parms-table\" class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappName\n\n</td><td>\n\nName of the application to associate with the configuration data. This application must be in the active state.Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr><tr><td>\n\nautoCommit\n\n</td><td>\n\nFlag that indicates whether the changeset identified in the **changesetNumber** parameter is committed to the data model after upload.Valid values:\n\n-   true: Changeset is committed after upload.\n-   false: Changeset isn't committed after upload.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nautoValidate\n\n</td><td>\n\nFlag that indicates whether the snapshots created when committed are validated.Valid values:\n\n-   true: Validate the snapshots.\n-   false: Don't validate the snapshots.\n\n**Note:** This option is only available if the **autoCommit** parameter is `true`.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nchangesetNumber\n\n</td><td>\n\nString that uniquely identifies the [changeset](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-changesets-version-control.md) associated with the application, such as Chset-102. This changeset must be in the \"Open\" state.Data type: String\n\nDefault: Creates a changeset to use. The changeset details are returned as part of the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) results.\n\nTable: CDM Changeset \\[sn\\_cdm\\_changeset\\]\n\n</td></tr><tr><td>\n\nfileName\n\n</td><td>\n\nName of the file to upload. This name can differ from than the actual file name and contain the file extension. For example, .txt/.scv/.jar. The fileName value is applied when downloading the file.Data type: String\n\n</td></tr><tr><td>\n\nfileNodeName\n\n</td><td>\n\nName of the file node. This file name is used in the configuration data when exporting it. This name doesn’t require a file extension nor does it affect the download.Data type: String\n\n</td></tr><tr><td>\n\nnamePath\n\n</td><td>\n\nPath of the targeted node under which the configuration data should be uploaded. This path is relative to the components, collection, or deployable folder \\(depending on the endpoint being called\\).You can pass the name path in any of the following formats. For example, to define the name path for the node `testApp/deployables/Development1/cdi1`:\n\n-   Backslash format: `testApp/deployables/Development1/cdi1`\n\n**Note:** If your node name contains a backslash \\(\"/\"\\), you can’t use this format.\n\n-   Backend name path with replacement characters: `testApp�deployables�​Development1​�​cdi1`\n-   Array: `['testApp','deployables','Development1','cdi1']`\n\n**Note:** If the specified component doesn't exist at the specified path, the system automatically creates the component at the specified path and then uploads the data.\n\nData type: String\n\n</td></tr><tr><td>\n\npublishOption\n\n</td><td id=\"publish_option-changeset-entry\">\n\nPublish option for the associated configured snapshots.\n\nValid values:\n\n-   publish\\_none: Don't publish any snapshots.\n-   publish\\_valid: Publish only those snapshots that pass validation after the commit.\n\nFor additional information on publishing snapshots, see [Publish or unpublish a snapshot](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-snapshot-publish.md).\n\nData type: String\n\nDefault: publish\\_none\n\n **Note:** This option is only available if the value for the **autoCommit** parameter is true.\n\n</td></tr></tbody>\n</table><table id=\"table_j22_fgm_2yb\" class=\"rest_api_request_body\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nVariable upload data\n\n</td><td>\n\nConfiguration data to upload. By default, file size uploads are limited to 5 MB. For information about how to adjust your upload file sizes and type, see this [Now Support article](https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0718101).Data type: String/stream\n\n</td></tr></tbody>\n</table>### Headers\n\n<table id=\"table_bd2_pqs_byb\" class=\"rest_api_request_headers\"><thead><tr><th>\n\nHeader\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nAccept\n\n</td><td id=\"accept-entry-RESTAPI\">\n\nData format of the response body. Supported types: **application/json** or **application/xml**. Default: **application/json**\n\n</td></tr><tr><td>\n\nContent-Type\n\n</td><td>\n\nData type of the file to be uploaded. Supported types: **application/zip**, **text/plain**, **application/json**.Default: **application/json**\n\n</td></tr></tbody>\n</table>|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table id=\"id_cdq_fft_byb\"><thead><tr><th>\n\nStatus code\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\n200\n\n</td><td id=\"entry-200-status-code\">\n\nSuccessful. The request was successfully processed.\n\n</td></tr><tr><td>\n\n400\n\n</td><td>\n\nBad request.Upload request has been rejected.\n\nPossible issues:\n\n-   Size of configuration payload is greater that the allowed maximum - 2 MB by default.\n-   Required parameters are missing from the call.\n\n</td></tr><tr><td>\n\n500\n\n</td><td id=\"entry-500-status-code\">\n\nInternal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.\n\n</td></tr></tbody>\n</table>### Response body parameters \\(JSON or XML\\)\n\n<table id=\"id_af3_kft_byb\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr id=\"cdm_apps-stat-error\"><td>\n\nerror\n\n</td><td>\n\nIf an error occurred during processing, the details about the error.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr id=\"cdm_apps-stat-error_detail-row\"><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_messaage-row\"><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_status-row\"><td>\n\nstatus\n\n</td><td>\n\nError status of the request.Possible values: failure\n\nData type: String\n\n</td></tr><tr id=\"cdm_apps-upload_id-row\"><td>\n\nupload\\_id\n\n</td><td>\n\nSys\\_id of the upload request. Use this ID to call the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to obtain the status of the upload.Data type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following example shows how to upload a content to a text file.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/uploads/components/file?autoValidate=true&appName=testApp&namePath=testComponent%2FfilesFolder&fileName=testFileNodeName.txt&publishOption=publish_valid&changesetNumber=Chset-108&autoCommit=true&fileNodeName=testFile.txt\" \\ \n--request POST \\ \n--header \"Accept:application/json\" \\ \n--header \"Content-Type:text/plain\" \\ \n--data \"This is sample content that will be uploaded to a plain text file.\"\\ \n--user 'username':'password' \n```\n\nThe following return results show both a successful and an error response for this request.\n\n```\n// Successful completion of the upload request\n{ \n  \"result\": { \n    \"upload_id\": \"ec1f71f45322301096edddeeff7b12b3\" \n  } \n} \n\n// Error response. Payload is too large.\n{ \n  \"error\": { \n    \"message\": \"Could not find active application with name: ‘testApp’ of type application\", \n    \"detail\": \"\" \n  },\n  \"status\": \"failure\"\n}\n\n```\n\n## CdmApplicationsApi - POST /sn\\_cdm/applications/uploads/components/vars\n\nSubmits a request to upload the passed-in configuration data under the vars folder, within the system components folder, for the specified application.\n\nThe following image shows an example of where the component's vars configuration data is uploaded in reference to the ServiceNow DevOps Config Workspace UI. Assumes the application is **paymentSvc**.\n\n\\[Omitted image \"apps-uploads-comp-vars\\_data.png\"\\] Alt text: Upload vars directory\n\n**Note:** The maximum default upload content size is 2 MB. You can modify this default by updating the property sn\\_cdm.max\\_allowed\\_upload\\_file\\_size.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/uploads/components/vars`\n\nDefault URL: `/api/sn_cdm/applications/uploads/components/vars`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table id=\"id_ey4_w13_psb\" class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappName\n\n</td><td>\n\nName of the application to associate with the configuration data. This application must be in the active state.Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr><tr><td>\n\nautoCommit\n\n</td><td>\n\nFlag that indicates whether the changeset identified in the **changesetNumber** parameter is committed to the data model after upload.Valid values:\n\n-   true: Changeset is committed after upload.\n-   false: Changeset isn't committed after upload.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nautoDelete\n\n</td><td>\n\nFlag that indicates whether the existing nodes, that aren’t part of the upload content, are deleted after the processing is complete.Valid values:\n\n-   true: Automatically delete existing nodes.\n-   false: Don't automatically delete existing nodes.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nautoValidate\n\n</td><td>\n\nFlag that indicates whether the snapshots created when committed are validated.Valid values:\n\n-   true: Validate the snapshots.\n-   false: Don't validate the snapshots.\n\n**Note:** This option is only available if the **autoCommit** parameter is `true`.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nchangesetNumber\n\n</td><td>\n\nString that uniquely identifies the [changeset](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-changesets-version-control.md) associated with the application, such as Chset-102. This changeset must be in the \"Open\" state.Data type: String\n\nDefault: Creates a changeset to use. The changeset details are returned as part of the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) results.\n\nTable: CDM Changeset \\[sn\\_cdm\\_changeset\\]\n\n</td></tr><tr id=\"cdm_apps-dataFormat-row\"><td>\n\ndataFormat\n\n</td><td>\n\nRequired. Format of the configuration data.Valid values:\n\n-   ini\n-   json\n-   properties\n-   raw\n-   xml\n-   yaml\n\nData type: String\n\n</td></tr><tr><td>\n\ndeleteRedundantOverrides\n\n</td><td>\n\nFlag that indicates whether to create an override where redundant values are present.Valid values:\n\n-   true: If redundant values are present, an override isn’t created.\n-   false: If redundant values are present, proceeds with an override.\n\nDefault: true\n\n</td></tr><tr><td>\n\nfileName\n\n</td><td>\n\nName of the file to upload. This name can differ from than the actual file name and contain the file extension. For example, .txt/.scv/.jar. The fileName value is applied when downloading the file.Data type: String\n\n</td></tr><tr><td>\n\nfileNodeName\n\n</td><td>\n\nName of the file node. This file name is used in the configuration data when exporting it. This name doesn’t require a file extension nor does it affect the download.Data type: String\n\n</td></tr><tr><td>\n\nidentifierKeys\n\n</td><td>\n\nList of names that indicate which key in an array child to use to identify the same node.For example, if you’re uploading:\n\n```\n[\n  {\"name\" : \"Allan, \"city\" : \"Paris\"}, \n  {\"name\" : \"Karen, \"city\" : \"Sydney\"}\n]\n```\n\nin the following existing model:\n\n```\n[\n  {\"name\" : \"Karen, \"city\" : \"Manila\"},\n  {\"name\" : \"Allan, \"city\" : \"Brussels\"}\n]\n```\n\nand you set **identifierKeys** to `name`, it produces the following output:\n\n```\n[\n  {\"name\" : \"Karen, \"city\" : \"Sydney\"},\n  {\"name\" : \"Allan, \"city\" : \"Paris\"}\n]\n```\n\nOtherwise, it produces the following output:\n\n```\n[\n  {\"name\" : \"Karen, \"city\" : \"Manila\"},\n  {\"name\" : \"Allan, \"city\" : \"Brussels\"},\n  {\"name\" : \"Allan, \"city\" : \"Paris\"},\n  {\"name\" : \"Karen, \"city\" : \"Sydney\"}\n]\n```\n\nData type: Array of Strings\n\n</td></tr><tr><td>\n\nignoreAttributes\n\n</td><td>\n\nFlag that indicates whether the given data format supports attributes \\(currently only XML\\).Valid values:\n\n-   true: If the given data format supports attributes, any attributes in the input data are skipped during the upload.\n-   false: If the given data format supports attributes, any attributes in the input data are included in the upload.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nnamePath\n\n</td><td>\n\nPath of the targeted node under which the configuration data should be uploaded. This path is relative to the components, collection, or deployable folder \\(depending on the endpoint being called\\).You can pass the name path in any of the following formats. For example, to define the name path for the node `testApp/deployables/Development1/cdi1`:\n\n-   Backslash format: `testApp/deployables/Development1/cdi1`\n\n**Note:** If your node name contains a backslash \\(\"/\"\\), you can’t use this format.\n\n-   Backend name path with replacement characters: `testApp�deployables�​Development1​�​cdi1`\n-   Array: `['testApp','deployables','Development1','cdi1']`\n\n**Note:** If the specified component doesn't exist at the specified path, the system automatically creates the component at the specified path and then uploads the data.\n\nData type: String\n\n</td></tr><tr><td>\n\nsharedLibraryName\n\n</td><td>\n\nRequired. Name of the shared library where the component to delete is located.Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|Variable upload data|Configuration data to upload. This can be any data in the format defined by the **dataFormat** parameter of the query parameters.|\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table id=\"id_cvs_bmb_fwb\" class=\"rest_api_request_headers\"><thead><tr><th>\n\nHeader\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nAccept\n\n</td><td id=\"accept-JSON-only-entry-RESTAPI\">\n\nData format of the response body. Only supports **application/json**.\n\n</td></tr><tr><td>\n\nContent-Type\n\n</td><td>\n\nData format of the request body. Supported types: **text/plain** and **application/x-www-form-urlencoded**.Default: **text/plain**\n\n</td></tr></tbody>\n</table>|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table id=\"id_dqr_z13_psb\"><thead><tr><th>\n\nStatus code\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\n200\n\n</td><td id=\"entry-200-status-code\">\n\nSuccessful. The request was successfully processed.\n\n</td></tr><tr><td>\n\n400\n\n</td><td>\n\nBad request.Upload request has been rejected.\n\nPossible issues:\n\n-   Size of configuration payload is greater that the allowed maximum - 2 MB by default.\n-   Required parameters are missing from the call.\n\n</td></tr><tr><td>\n\n500\n\n</td><td id=\"entry-500-status-code\">\n\nInternal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.\n\n</td></tr></tbody>\n</table>### Response body parameters \\(JSON or XML\\)\n\n<table id=\"id_pcq_1b3_psb\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr id=\"cdm_apps-stat-error\"><td>\n\nerror\n\n</td><td>\n\nIf an error occurred during processing, the details about the error.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr id=\"cdm_apps-stat-error_detail-row\"><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_messaage-row\"><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_status-row\"><td>\n\nstatus\n\n</td><td>\n\nError status of the request.Possible values: failure\n\nData type: String\n\n</td></tr><tr id=\"cdm_apps-upload_id-row\"><td>\n\nupload\\_id\n\n</td><td>\n\nSys\\_id of the upload request. Use this ID to call the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to obtain the status of the upload.Data type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following example shows a vars upload request for the application Demo\\_App1631126164773.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/uploads/components/vars?changesetNumber=Chset-102&autoValidate=false&autoDelete=true&publishOption=publish_none&appName=Demo_App1631126164773&namePath=%2FSettings%2FdbSettings&autoCommit=false&dataFormat=json\" \\ \n--request POST \\ \n--header \"Accept:application/json\" \\ \n--header \"Content-Type:text/plain\" \\ \n--data \"{ \n  \\\"dbSettings\\\": { \n    \\\"dbIPAddress\\\": \\\"10.10.10.110\\\", \n    \\\"dbPort\\\": \\\"8080\\\", \n    \\\"dbConnectionString\\\": \\\"username:password server1.xyz.com:8080 dbName_payments\\\", \n    \\\"dbConnectionStringBackup\\\": \\\"username:password server2.xyz.com dbName_payments_backup\\\"\n  } \n}\"\n--user 'username':'password' \n```\n\nThe following return results show both a successful and an error response for this request.\n\n```\n// Successful completion of the upload request\n{ \n  \"result\": { \n    \"upload_id\": \"d21f71f45322301096eccceaff7b1ce3\" \n  } \n} \n\n// Error response. Payload is too large.\n{ \n  \"error\": { \n    \"message\": \"Size of uploaded data:6853632.0(bytes) is greater than max allowed upload limit of 2097152.0(bytes)\", \n    \"detail\": \"\" \n  },\n  \"status\": \"failure\"\n}\n```\n\n## CdmApplicationsApi - POST /sn\\_cdm/applications/uploads/collections\n\nSubmits a request to upload the passed-in configuration data for a specific collection, within the system collections folder, for the specified application.\n\nThis endpoint returns the ID of the upload request. Use this ID to call the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to obtain the status of the upload.\n\n**Note:** The maximum default upload content size is 2 MB. You can modify this default by updating the property sn\\_cdm.max\\_allowed\\_upload\\_file\\_size.\n\nThe following image shows an example of where the configuration data is uploaded in reference to the ServiceNow DevOps Config Workspace UI. Assumes the collection is **db0Release1.0** and the application is **paymentSvc**.\n\n\\[Omitted image \"apps-uploads-collections\\_data.png\"\\] Alt text: Collections upload folder\n\n**Note:** This upload method cannot be used to modify nodes. Use the alternative [CdmApplicationsApi - POST /sn\\_cdm/applications/uploads/collections/file](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) method to modify nodes.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/uploads/collections`\n\nDefault URL: `/api/sn_cdm/applications/uploads/collections`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table id=\"id_ycw_c33_psb\" class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappName\n\n</td><td>\n\nName of the application to associate with the configuration data. This application must be in the active state.Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr><tr><td>\n\nautoCommit\n\n</td><td>\n\nFlag that indicates whether the changeset identified in the **changesetNumber** parameter is committed to the data model after upload.Valid values:\n\n-   true: Changeset is committed after upload.\n-   false: Changeset isn't committed after upload.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nautoDelete\n\n</td><td>\n\nFlag that indicates whether the existing nodes, that aren’t part of the upload content, are deleted after the processing is complete.Valid values:\n\n-   true: Automatically delete existing nodes.\n-   false: Don't automatically delete existing nodes.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nautoValidate\n\n</td><td>\n\nFlag that indicates whether the snapshots created when committed are validated.Valid values:\n\n-   true: Validate the snapshots.\n-   false: Don't validate the snapshots.\n\n**Note:** This option is only available if the **autoCommit** parameter is `true`.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nchangesetNumber\n\n</td><td>\n\nString that uniquely identifies the [changeset](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-changesets-version-control.md) associated with the application, such as Chset-102. This changeset must be in the \"Open\" state.Data type: String\n\nDefault: Creates a changeset to use. The changeset details are returned as part of the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) results.\n\nTable: CDM Changeset \\[sn\\_cdm\\_changeset\\]\n\n</td></tr><tr><td>\n\ncollectionName\n\n</td><td>\n\nRequired. Name of the collection under which to store the uploaded payload. **Note:** If the specified **namePath** does not exist under this collection, the system automatically creates the component\\(s\\) under this collection and then uploads the configuration content. For example, if you want to upload the collection `collA`, with the path `compA/comp/compC`, the data is uploaded under `/collA/collections/compa/compB/compC`.\n\nIf `compA` exists but not `compB` and `compC`, then the endpoint creates these components and uploads the data under `compC`.\n\nData type: String\n\n</td></tr><tr><td>\n\ndataFormat\n\n</td><td>\n\nRequired. Format of the configuration data.Valid values:\n\n-   csv\n-   ini\n-   json\n-   properties\n-   raw\n-   xml\n-   yaml\n\nData type: String\n\n</td></tr><tr><td>\n\ndataFormatAttributes\n\n</td><td id=\"cdm_app-dataFormAtt-entry\">\n\nOnly supported when the **dataFormat** parameter is set to `csv`. Attributes that define the CSV data format. For additional information, see [Parsing of CSV files in CDM](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-parsing-csv-file.md).Data type: Object\n\n```\n\"dataFormatAttributes\" {\n  \"containsHeader\": Boolean,\n  \"delimeter\": \"String\"\n  \"headers\": [Array],\n  \"securedHeaders\": [Array]\n}\n```\n\n</td></tr><tr><td>\n\ndataFormatAttributes.containsHeaders\n\n</td><td id=\"cdm_app-dataFormAtt_containsHeaders-entry\">\n\nFlag that indicates whether the data contains a header row.Valid values:\n\n-   true: Data contains a header row. The first row in the data is considered the header row.\n\n\\[Omitted image \"cdm\\_header\\_row\\_example.png\"\\] Alt text: Header row example\n\n-   false: Data doesn't contain a header row. You must pass the header information in the **dataFormatAttributes.headers** parameter.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\ndataFormatAttributes.delimeter\n\n</td><td id=\"cdm_app-dataFormAtt_delimeter-entry\">\n\nCharacter to use to delineate fields within the data.Data type: String\n\nDefault: Comma \",\"\n\n</td></tr><tr><td>\n\ndataFormatAttributes.headers\n\n</td><td id=\"cdm_app-dataFormAtt_headers-entry\">\n\nRequired if **dataFormatAttributes.containsHeaders** parameter is `false`. Fields in the data that comprise the header. These headers are converted to the key names of the CDIs in the JSON format. The number of headers must match the number of record fields.Data type: Array\n\nDefault: Empty array\n\n</td></tr><tr><td>\n\ndataFormatAttributes.securedHeaders\n\n</td><td id=\"cdm_app-dataFormAtt_securedHeaders-entry\">\n\nFields in the data that are secure fields and must be encrypted in the data uploaded to CDM. The name of the secured headers must match the name of the headers in the headers attribute or data file. These fields are stored in a column of type Password \\(2 Way Encrypted\\).**Note:** You can only secure fields using this attribute. You can't unsecure the secured fields.\n\nData type: Array\n\nDefault: Empty array\n\n</td></tr><tr><td>\n\ndeleteRedundantOverrides\n\n</td><td>\n\nFlag that indicates whether to create an override where redundant values are present.Valid values:\n\n-   true: If redundant values are present, an override isn’t created.\n-   false: If redundant values are present, proceeds with an override.\n\nDefault: true\n\n</td></tr><tr><td>\n\nignoreAttributes\n\n</td><td>\n\nFlag that indicates whether the given data format supports attributes \\(currently only XML\\).Valid values:\n\n-   true: If the given data format supports attributes, any attributes in the input data are skipped during the upload.\n-   false: If the given data format supports attributes, any attributes in the input data are included in the upload.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nnamePath\n\n</td><td>\n\nPath of the targeted node under which the configuration data should be uploaded. This path is relative to the components, collection, or deployable folder \\(depending on the endpoint being called\\).You can pass the name path in any of the following formats. For example, to define the name path for the node `testApp/deployables/Development1/cdi1`:\n\n-   Backslash format: `testApp/deployables/Development1/cdi1`\n\n**Note:** If your node name contains a backslash \\(\"/\"\\), you can’t use this format.\n\n-   Backend name path with replacement characters: `testApp�deployables�​Development1​�​cdi1`\n-   Array: `['testApp','deployables','Development1','cdi1']`\n\n**Note:** If the specified component doesn't exist at the specified path, the system automatically creates the component at the specified path and then uploads the data.\n\nData type: String\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|Variable upload data|Configuration data to upload. This can be any data in the format defined by the **dataFormat** parameter of the query parameters.|\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table id=\"id_h4r_fmb_fwb\" class=\"rest_api_request_headers\"><thead><tr><th>\n\nHeader\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nAccept\n\n</td><td id=\"accept-JSON-only-entry-RESTAPI\">\n\nData format of the response body. Only supports **application/json**.\n\n</td></tr><tr><td>\n\nContent-Type\n\n</td><td>\n\nData format of the request body. Supported types: **text/plain** and **application/x-www-form-urlencoded**.Default: **text/plain**\n\n</td></tr></tbody>\n</table>|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table id=\"id_szz_f33_psb\"><thead><tr><th>\n\nStatus code\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\n200\n\n</td><td id=\"entry-200-status-code\">\n\nSuccessful. The request was successfully processed.\n\n</td></tr><tr><td>\n\n400\n\n</td><td>\n\nBad request.Upload request has been rejected.\n\nPossible issues:\n\n-   Size of configuration payload is greater that the allowed maximum - 2 MB by default.\n-   Required parameters are missing from the call.\n\n</td></tr><tr><td>\n\n500\n\n</td><td id=\"entry-500-status-code\">\n\nInternal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.\n\n</td></tr></tbody>\n</table>### Response body parameters \\(JSON or XML\\)\n\n<table id=\"id_i55_g33_psb\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr id=\"cdm_apps-stat-error\"><td>\n\nerror\n\n</td><td>\n\nIf an error occurred during processing, the details about the error.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr id=\"cdm_apps-stat-error_detail-row\"><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_messaage-row\"><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_status-row\"><td>\n\nstatus\n\n</td><td>\n\nError status of the request.Possible values: failure\n\nData type: String\n\n</td></tr><tr id=\"cdm_apps-upload_id-row\"><td>\n\nupload\\_id\n\n</td><td>\n\nSys\\_id of the upload request. Use this ID to call the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to obtain the status of the upload.Data type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThis example shows how to upload JSON-formatted **dbSettings** configuration date into the collections folder for the application Demo\\_App1631126164773.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/uploads/collections?dataFormat=json&autoValidate=false&changesetNumber=Chset-102&appName=Demo_App1631126164773&autoDelete=true&namePath=%2FSettings%2FdbSettings&collectionName=release-1.0&autoCommit=false&publishOption=publish_none\" \\ \n--request POST \\ \n--header \"Accept:application/json\" \\ \n--header \"Content-Type:text/plain\" \\ \n--data \"{ \n  \\\"dbSettings\\\": { \n    \\\"dbIPAddress\\\": \\\"10.10.10.110\\\", \n    \\\"dbPort\\\": \\\"8080\\\", \n    \\\"dbConnectionString\\\": \\\"admin:admin server1.xyz.com:8080 dbName_payments\\\", \n    \\\"dbConnectionStringBackup\\\": \\\"admin:admin server2.xyz.com dbName_payments_backup\\\" \n  } \n}\" \\ \n--user 'username':'password' \n```\n\nThe following shows the possible responses to this call, both as a success and an error.\n\n```\n// Successful completion of the upload request\n{ \n  \"result\": { \n    \"upload_id\": \"ec1f71f45322301096edddeeff7b12b3\" \n  } \n} \n\n// Error response. Payload is too large.\n{ \n  \"error\": { \n    \"message\": \"Size of uploaded data:6853632.0(bytes) is greater than max allowed upload limit of 2097152.0(bytes)\", \n    \"detail\": \"\" \n  },\n  \"status\": \"failure\"\n}\n```\n\n## CdmApplicationsApi - POST /sn\\_cdm/applications/uploads/collections/file\n\nUploads a file to the collections folder in the Configuration Data Model \\(CDM\\).\n\n### URL format\n\nVersioned URL: `POST /api/sn_cdm/{api_version}/applications/uploads/collections/file`\n\nDefault URL: `POST /api/sn_cdm/applications/uploads/collections/file`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table id=\"table_rgl_tbt_byb\" class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table id=\"cdm_app-upload_query_parms-table\" class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappName\n\n</td><td>\n\nName of the application to associate with the configuration data. This application must be in the active state.Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr><tr><td>\n\nautoCommit\n\n</td><td>\n\nFlag that indicates whether the changeset identified in the **changesetNumber** parameter is committed to the data model after upload.Valid values:\n\n-   true: Changeset is committed after upload.\n-   false: Changeset isn't committed after upload.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nautoValidate\n\n</td><td>\n\nFlag that indicates whether the snapshots created when committed are validated.Valid values:\n\n-   true: Validate the snapshots.\n-   false: Don't validate the snapshots.\n\n**Note:** This option is only available if the **autoCommit** parameter is `true`.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\ncollectionName\n\n</td><td>\n\nRequired. Name of the collection under which to store the uploaded payload.**Note:** If the specified `namePath` does not exist under this collection, the system automatically creates the component\\(s\\) under this collection and then uploads the configuration content. For example, if you want to upload the collection `collA`, with the path `compA/comp/compC`, the data is uploaded under `/collA/collections/compa/compB/compC`. If `compA` exists but not `compB` and `compC`, then the endpoint creates these components and uploads the data under `compC`.\n\nData type: String\n\n</td></tr><tr><td>\n\nchangesetNumber\n\n</td><td>\n\nString that uniquely identifies the [changeset](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-changesets-version-control.md) associated with the application, such as Chset-102. This changeset must be in the \"Open\" state.Data type: String\n\nDefault: Creates a changeset to use. The changeset details are returned as part of the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) results.\n\nTable: CDM Changeset \\[sn\\_cdm\\_changeset\\]\n\n</td></tr><tr><td>\n\nfileName\n\n</td><td>\n\nName of the file to upload. This name can differ from than the actual file name and contain the file extension. For example, .txt/.scv/.jar. The fileName value is applied when downloading the file.Data type: String\n\n</td></tr><tr><td>\n\nfileNodeName\n\n</td><td>\n\nName of the file node. This file name is used in the configuration data when exporting it. This name doesn’t require a file extension nor does it affect the download.Data type: String\n\n</td></tr><tr><td>\n\nnamePath\n\n</td><td>\n\nPath of the targeted node under which the configuration data should be uploaded. This path is relative to the components, collection, or deployable folder \\(depending on the endpoint being called\\).You can pass the name path in any of the following formats. For example, to define the name path for the node `testApp/deployables/Development1/cdi1`:\n\n-   Backslash format: `testApp/deployables/Development1/cdi1`\n\n**Note:** If your node name contains a backslash \\(\"/\"\\), you can’t use this format.\n\n-   Backend name path with replacement characters: `testApp�deployables�​Development1​�​cdi1`\n-   Array: `['testApp','deployables','Development1','cdi1']`\n\n**Note:** If the specified component doesn't exist at the specified path, the system automatically creates the component at the specified path and then uploads the data.\n\nData type: String\n\n</td></tr><tr><td>\n\npublishOption\n\n</td><td id=\"publish_option-changeset-entry\">\n\nPublish option for the associated configured snapshots.\n\nValid values:\n\n-   publish\\_none: Don't publish any snapshots.\n-   publish\\_valid: Publish only those snapshots that pass validation after the commit.\n\nFor additional information on publishing snapshots, see [Publish or unpublish a snapshot](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-snapshot-publish.md).\n\nData type: String\n\nDefault: publish\\_none\n\n **Note:** This option is only available if the value for the **autoCommit** parameter is true.\n\n</td></tr></tbody>\n</table><table id=\"table_j22_fgm_2yb\" class=\"rest_api_request_body\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nVariable upload data\n\n</td><td>\n\nConfiguration data to upload. By default, file size uploads are limited to 5 MB. For information about how to adjust your upload file sizes and type, see this [Now Support article](https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0718101).Data type: String/stream\n\n</td></tr></tbody>\n</table>### Headers\n\n<table id=\"table_enr_pqs_byb\" class=\"rest_api_request_headers\"><thead><tr><th>\n\nHeader\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nAccept\n\n</td><td id=\"accept-entry-RESTAPI\">\n\nData format of the response body. Supported types: **application/json** or **application/xml**. Default: **application/json**\n\n</td></tr><tr><td>\n\nContent-Type\n\n</td><td>\n\nContent Type of the file to be uploaded. Examples: application/zip, text/plain, application/json.\n\n</td></tr></tbody>\n</table>|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table id=\"id_cdq_fft_byb\"><thead><tr><th>\n\nStatus code\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\n200\n\n</td><td id=\"entry-200-status-code\">\n\nSuccessful. The request was successfully processed.\n\n</td></tr><tr><td>\n\n400\n\n</td><td>\n\nBad request.Upload request has been rejected.\n\nPossible issues:\n\n-   Size of configuration payload is greater that the allowed maximum - 2 MB by default.\n-   Required parameters are missing from the call.\n\n</td></tr><tr><td>\n\n500\n\n</td><td id=\"entry-500-status-code\">\n\nInternal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.\n\n</td></tr></tbody>\n</table>### Response body parameters \\(JSON or XML\\)\n\n<table id=\"table_gft_zht_byb\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr id=\"cdm_apps-stat-error\"><td>\n\nerror\n\n</td><td>\n\nIf an error occurred during processing, the details about the error.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr id=\"cdm_apps-stat-error_detail-row\"><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_messaage-row\"><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_status-row\"><td>\n\nstatus\n\n</td><td>\n\nError status of the request.Possible values: failure\n\nData type: String\n\n</td></tr><tr id=\"cdm_apps-upload_id-row\"><td>\n\nupload\\_id\n\n</td><td>\n\nSys\\_id of the upload request. Use this ID to call the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to obtain the status of the upload.Data type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following call uploads a plain text file to the CDM collections folder.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/uploads/collections/file?autoValidate=true&collectionName=collA&appName=testApp&namePath=testComponent%2FfilesFolder&fileName=testFileNodeName.txt&publishOption=publish_valid&changesetNumber=Chset-108&autoCommit=true&fileNodeName=testFile.txt\" \\ \n--request POST \\ \n--header \"Accept:application/json\" \\ \n--header \"Content-Type:text/plain\" \\ \n--data \"This is sample content that will be uploaded to a plain text file.\"\\ \n--user 'username':'password'\n```\n\nThe following return results show both a successful and an error response to this request.\n\n```\n// Successful completion of the upload request\n{ \n  \"result\": { \n    \"upload_id\": \"ec1f71f45322301096edddeeff7b12b3\" \n  } \n} \n\n// Error response. Payload is too large.\n{ \n  \"error\": { \n    \"message\": \"Could not find active application with name: ‘testApp’ of type application\", \n    \"detail\": \"\" \n  },\n  \"status\": \"failure\"\n}\n```\n\n## CdmApplicationsApi - POST /sn\\_cdm/applications/uploads/deployables\n\nSubmits a request to upload the configuration content for a specific deployable within the deployables system folder of a specified application.\n\nThis endpoint returns the ID of the upload request. Use this ID to call the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to obtain the status of the upload.\n\n**Note:** The maximum default upload content size is 2 MB. You can modify this default by updating the property sn\\_cdm.max\\_allowed\\_upload\\_file\\_size.\n\nThe following image shows an example of where the deployable configuration data is uploaded in reference to the ServiceNow DevOps Config UI. Assumes the deployable is **Development\\_1** and the application is **paymentSvc**.\n\n\\[Omitted image \"apps-uploads-deployables\\_data.png\"\\] Alt text: Deployables config data location in UI\n\n**Note:** This upload method cannot be used to modify nodes. Use the alternative [CdmApplicationsApi - POST /sn\\_cdm/applications/uploads/deployables/file](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) method to modify nodes.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/uploads/deployables`\n\nDefault URL: `/api/sn_cdm/applications/uploads/deployables`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappName\n\n</td><td>\n\nName of the application to associate with the configuration data. This application must be in the active state.Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr><tr><td>\n\nautoCommit\n\n</td><td>\n\nFlag that indicates whether the changeset identified in the **changesetNumber** parameter is committed to the data model after upload.Valid values:\n\n-   true: Changeset is committed after upload.\n-   false: Changeset isn't committed after upload.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nautoDelete\n\n</td><td>\n\nFlag that indicates whether the existing nodes, that aren’t part of the upload content, are deleted after the processing is complete.Valid values:\n\n-   true: Automatically delete existing nodes.\n-   false: Don't automatically delete existing nodes.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nautoValidate\n\n</td><td>\n\nFlag that indicates whether the snapshots created when committed are validated.Valid values:\n\n-   true: Validate the snapshots.\n-   false: Don't validate the snapshots.\n\n**Note:** This option is only available if the **autoCommit** parameter is `true`.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nchangesetNumber\n\n</td><td>\n\nString that uniquely identifies the [changeset](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-changesets-version-control.md) associated with the application, such as Chset-102. This changeset must be in the \"Open\" state.Data type: String\n\nDefault: Creates a changeset to use. The changeset details are returned as part of the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) results.\n\nTable: CDM Changeset \\[sn\\_cdm\\_changeset\\]\n\n</td></tr><tr><td>\n\ndataFormat\n\n</td><td>\n\nRequired. Format of the configuration data.Valid values:\n\n-   csv\n-   ini\n-   json\n-   properties\n-   raw\n-   xml\n-   yaml\n\nData type: String\n\n</td></tr><tr><td>\n\ndataFormatAttributes\n\n</td><td id=\"cdm_app-dataFormAtt-entry\">\n\nOnly supported when the **dataFormat** parameter is set to `csv`. Attributes that define the CSV data format. For additional information, see [Parsing of CSV files in CDM](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-parsing-csv-file.md).Data type: Object\n\n```\n\"dataFormatAttributes\" {\n  \"containsHeader\": Boolean,\n  \"delimeter\": \"String\"\n  \"headers\": [Array],\n  \"securedHeaders\": [Array]\n}\n```\n\n</td></tr><tr><td>\n\ndataFormatAttributes.containsHeaders\n\n</td><td id=\"cdm_app-dataFormAtt_containsHeaders-entry\">\n\nFlag that indicates whether the data contains a header row.Valid values:\n\n-   true: Data contains a header row. The first row in the data is considered the header row.\n\n\\[Omitted image \"cdm\\_header\\_row\\_example.png\"\\] Alt text: Header row example\n\n-   false: Data doesn't contain a header row. You must pass the header information in the **dataFormatAttributes.headers** parameter.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\ndataFormatAttributes.delimeter\n\n</td><td id=\"cdm_app-dataFormAtt_delimeter-entry\">\n\nCharacter to use to delineate fields within the data.Data type: String\n\nDefault: Comma \",\"\n\n</td></tr><tr><td>\n\ndataFormatAttributes.headers\n\n</td><td id=\"cdm_app-dataFormAtt_headers-entry\">\n\nRequired if **dataFormatAttributes.containsHeaders** parameter is `false`. Fields in the data that comprise the header. These headers are converted to the key names of the CDIs in the JSON format. The number of headers must match the number of record fields.Data type: Array\n\nDefault: Empty array\n\n</td></tr><tr><td>\n\ndataFormatAttributes.securedHeaders\n\n</td><td id=\"cdm_app-dataFormAtt_securedHeaders-entry\">\n\nFields in the data that are secure fields and must be encrypted in the data uploaded to CDM. The name of the secured headers must match the name of the headers in the headers attribute or data file. These fields are stored in a column of type Password \\(2 Way Encrypted\\).**Note:** You can only secure fields using this attribute. You can't unsecure the secured fields.\n\nData type: Array\n\nDefault: Empty array\n\n</td></tr><tr><td>\n\ndeleteRedundantOverrides\n\n</td><td>\n\nFlag that indicates whether to create an override where redundant values are present.Valid values:\n\n-   true: If redundant values are present, an override isn’t created.\n-   false: If redundant values are present, proceeds with an override.\n\nDefault: true\n\n</td></tr><tr><td>\n\ndeployableName\n\n</td><td>\n\nRequired. Name of the deployable under which to store the uploaded payload. **Note:** If the specified **namePath** does not exist under this deployable, the system automatically creates the component\\(s\\) under this deployable and then uploads the configuration content.\n\n</td></tr><tr><td>\n\nidentifierKeys\n\n</td><td>\n\nList of names that indicate which key in an array child to use to identify the same node.For example, if you’re uploading:\n\n```\n[\n  {\"name\" : \"Allan, \"city\" : \"Paris\"}, \n  {\"name\" : \"Karen, \"city\" : \"Sydney\"}\n]\n```\n\nin the following existing model:\n\n```\n[\n  {\"name\" : \"Karen, \"city\" : \"Manila\"},\n  {\"name\" : \"Allan, \"city\" : \"Brussels\"}\n]\n```\n\nand you set **identifierKeys** to `name`, it produces the following output:\n\n```\n[\n  {\"name\" : \"Karen, \"city\" : \"Sydney\"},\n  {\"name\" : \"Allan, \"city\" : \"Paris\"}\n]\n```\n\nOtherwise, it produces the following output:\n\n```\n[\n  {\"name\" : \"Karen, \"city\" : \"Manila\"},\n  {\"name\" : \"Allan, \"city\" : \"Brussels\"},\n  {\"name\" : \"Allan, \"city\" : \"Paris\"},\n  {\"name\" : \"Karen, \"city\" : \"Sydney\"}\n]\n```\n\nData type: Array of Strings\n\n</td></tr><tr><td>\n\nignoreAttributes\n\n</td><td>\n\nFlag that indicates whether the given data format supports attributes \\(currently only XML\\).Valid values:\n\n-   true: If the given data format supports attributes, any attributes in the input data are skipped during the upload.\n-   false: If the given data format supports attributes, any attributes in the input data are included in the upload.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nnamePath\n\n</td><td>\n\nPath of the targeted node under which the configuration data should be uploaded. This path is relative to the components, collection, or deployable folder \\(depending on the endpoint being called\\).You can pass the name path in any of the following formats. For example, to define the name path for the node `testApp/deployables/Development1/cdi1`:\n\n-   Backslash format: `testApp/deployables/Development1/cdi1`\n\n**Note:** If your node name contains a backslash \\(\"/\"\\), you can’t use this format.\n\n-   Backend name path with replacement characters: `testApp�deployables�​Development1​�​cdi1`\n-   Array: `['testApp','deployables','Development1','cdi1']`\n\n**Note:** If the specified component doesn't exist at the specified path, the system automatically creates the component at the specified path and then uploads the data.\n\nData type: String\n\n</td></tr><tr><td>\n\npublishOption\n\n</td><td id=\"publish_option-changeset-entry\">\n\nPublish option for the associated configured snapshots.\n\nValid values:\n\n-   publish\\_none: Don't publish any snapshots.\n-   publish\\_valid: Publish only those snapshots that pass validation after the commit.\n\nFor additional information on publishing snapshots, see [Publish or unpublish a snapshot](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-snapshot-publish.md).\n\nData type: String\n\nDefault: publish\\_none\n\n **Note:** This option is only available if the value for the **autoCommit** parameter is true.\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|Variable upload data|Configuration data to upload. This can be any data in the format defined by the **dataFormat** parameter of the query parameters.|\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table id=\"id_ilq_dmb_fwb\" class=\"rest_api_request_headers\"><thead><tr><th>\n\nHeader\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nAccept\n\n</td><td id=\"accept-JSON-only-entry-RESTAPI\">\n\nData format of the response body. Only supports **application/json**.\n\n</td></tr><tr><td>\n\nContent-Type\n\n</td><td>\n\nData format of the request body. Supported types: **text/plain** and **application/x-www-form-urlencoded**.Default: **text/plain**\n\n</td></tr></tbody>\n</table>|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table id=\"id_gty_cw3_psb\"><thead><tr><th>\n\nStatus code\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\n200\n\n</td><td id=\"entry-200-status-code\">\n\nSuccessful. The request was successfully processed.\n\n</td></tr><tr><td>\n\n400\n\n</td><td>\n\nBad request.Upload request has been rejected.\n\nPossible issues:\n\n-   Size of configuration payload is greater that the allowed maximum - 2 MB by default.\n-   Required parameters are missing from the call.\n\n</td></tr><tr><td>\n\n500\n\n</td><td id=\"entry-500-status-code\">\n\nInternal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.\n\n</td></tr></tbody>\n</table>### Response body parameters \\(JSON or XML\\)\n\n<table id=\"id_gcv_2w3_psb\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr id=\"cdm_apps-stat-error\"><td>\n\nerror\n\n</td><td>\n\nIf an error occurred during processing, the details about the error.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr id=\"cdm_apps-stat-error_detail-row\"><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_messaage-row\"><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_status-row\"><td>\n\nstatus\n\n</td><td>\n\nError status of the request.Possible values: failure\n\nData type: String\n\n</td></tr><tr id=\"cdm_apps-upload_id-row\"><td>\n\nupload\\_id\n\n</td><td>\n\nSys\\_id of the upload request. Use this ID to call the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to obtain the status of the upload.Data type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following example shows an upload request for the application Demo\\_App1631126164773.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/uploads/deployables?deployableName=TST-1&autoValidate=false&dataFormat=json&autoDelete=false&changesetNumber=Chset-102&appName=Demo_App1631126164773&publishOption=publish_none&autoCommit=true&namePath=%2FSettings%2FdbSettings\" \\ \n--request POST \\ \n--header \"Accept:application/json\" \\ \n--header \"Content-Type:text/plain\" \\ \n--data \"{\n  \\\"dbIPAddress\\\": \\\"10.10.10.110\\\",\n  \\\"dbPort\\\": \\\"8080\\\",\n  \\\"dbConnectionString\\\": \\\"admin:admin server1.xyz.com:8080 dbName_payments\\\",\n  \\\"dbConnectionStringBackup\\\": \\\"admin:admin server2.xyz.com dbName_payments_backup\\\"\n}\" \\ \n--user 'username':'password' \n```\n\nThe following return results show both a successful and an error response for this request.\n\n```\n// Successful completion of the upload request\n{ \n  \"result\": { \n    \"upload_id\": \"ec1f71f45322301096edddeeff7b12b3\" \n  } \n} \n\n// Error response. Payload is too large.\n{ \n  \"error\": { \n    \"message\": \"Size of uploaded data:6853632.0(bytes) is greater than max allowed upload limit of 2097152.0(bytes)\", \n    \"detail\": \"\" \n  },\n  \"status\": \"failure\"\n}\n```\n\n## CdmApplicationsApi - POST /sn\\_cdm/applications/uploads/deployables/file\n\nUploads files to the deployables folder in the Configuration Data Model \\(CDM\\).\n\n### URL format\n\nVersioned URL: `POST /api/sn_cdm/{api_version}/applications/uploads/deployables/file`\n\nDefault URL: `POST /api/sn_cdm/applications/uploads/deployables/file`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table id=\"table_rgl_tbt_byb\" class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table id=\"cdm_app-upload_query_parms-table\" class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappName\n\n</td><td>\n\nName of the application to associate with the configuration data. This application must be in the active state.Data type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr><tr><td>\n\nautoCommit\n\n</td><td>\n\nFlag that indicates whether the changeset identified in the **changesetNumber** parameter is committed to the data model after upload.Valid values:\n\n-   true: Changeset is committed after upload.\n-   false: Changeset isn't committed after upload.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nautoValidate\n\n</td><td>\n\nFlag that indicates whether the snapshots created when committed are validated.Valid values:\n\n-   true: Validate the snapshots.\n-   false: Don't validate the snapshots.\n\n**Note:** This option is only available if the **autoCommit** parameter is `true`.\n\nData type: Boolean\n\nDefault: false\n\n</td></tr><tr><td>\n\nchangesetNumber\n\n</td><td>\n\nString that uniquely identifies the [changeset](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-changesets-version-control.md) associated with the application, such as Chset-102. This changeset must be in the \"Open\" state.Data type: String\n\nDefault: Creates a changeset to use. The changeset details are returned as part of the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) results.\n\nTable: CDM Changeset \\[sn\\_cdm\\_changeset\\]\n\n</td></tr><tr><td>\n\ndeployableName\n\n</td><td id=\"deployableName-policy-entry\">\n\nRequired. Name of the CDM deployable for which to map the policy.Data type: String\n\nTable: CDM Deployable \\[sn\\_cdm\\_deployable\\]\n\n</td></tr><tr><td>\n\nfileName\n\n</td><td>\n\nName of the file to upload. This name can differ from than the actual file name and contain the file extension. For example, .txt/.scv/.jar. The fileName value is applied when downloading the file.Data type: String\n\n</td></tr><tr><td>\n\nfileNodeName\n\n</td><td>\n\nName of the file node. This file name is used in the configuration data when exporting it. This name doesn’t require a file extension nor does it affect the download.Data type: String\n\n</td></tr><tr><td>\n\nnamePath\n\n</td><td>\n\nPath of the targeted node under which the configuration data should be uploaded. This path is relative to the components, collection, or deployable folder \\(depending on the endpoint being called\\).You can pass the name path in any of the following formats. For example, to define the name path for the node `testApp/deployables/Development1/cdi1`:\n\n-   Backslash format: `testApp/deployables/Development1/cdi1`\n\n**Note:** If your node name contains a backslash \\(\"/\"\\), you can’t use this format.\n\n-   Backend name path with replacement characters: `testApp�deployables�​Development1​�​cdi1`\n-   Array: `['testApp','deployables','Development1','cdi1']`\n\n**Note:** If the specified component doesn't exist at the specified path, the system automatically creates the component at the specified path and then uploads the data.\n\nData type: String\n\n</td></tr><tr><td>\n\npublishOption\n\n</td><td id=\"publish_option-changeset-entry\">\n\nPublish option for the associated configured snapshots.\n\nValid values:\n\n-   publish\\_none: Don't publish any snapshots.\n-   publish\\_valid: Publish only those snapshots that pass validation after the commit.\n\nFor additional information on publishing snapshots, see [Publish or unpublish a snapshot](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/it-service-management/cdm-snapshot-publish.md).\n\nData type: String\n\nDefault: publish\\_none\n\n **Note:** This option is only available if the value for the **autoCommit** parameter is true.\n\n</td></tr></tbody>\n</table><table id=\"table_j22_fgm_2yb\" class=\"rest_api_request_body\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nVariable upload data\n\n</td><td>\n\nConfiguration data to upload. By default, file size uploads are limited to 5 MB. For information about how to adjust your upload file sizes and type, see this [Now Support article](https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0718101).Data type: String/stream\n\n</td></tr></tbody>\n</table>### Headers\n\n<table id=\"table_bd2_pqs_byb\" class=\"rest_api_request_headers\"><thead><tr><th>\n\nHeader\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nAccept\n\n</td><td id=\"accept-entry-RESTAPI\">\n\nData format of the response body. Supported types: **application/json** or **application/xml**. Default: **application/json**\n\n</td></tr><tr><td>\n\nContent-Type\n\n</td><td>\n\nData type of the file to be uploaded. Supported types: **application/zip**, **text/plain**, **application/json**.Default: **application/json**\n\n</td></tr></tbody>\n</table>|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table id=\"id_cdq_fft_byb\"><thead><tr><th>\n\nStatus code\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\n200\n\n</td><td id=\"entry-200-status-code\">\n\nSuccessful. The request was successfully processed.\n\n</td></tr><tr><td>\n\n400\n\n</td><td>\n\nBad request.Upload request has been rejected.\n\nPossible issues:\n\n-   Size of configuration payload is greater that the allowed maximum - 2 MB by default.\n-   Required parameters are missing from the call.\n\n</td></tr><tr><td>\n\n500\n\n</td><td id=\"entry-500-status-code\">\n\nInternal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.\n\n</td></tr></tbody>\n</table>### Response body parameters \\(JSON or XML\\)\n\n<table id=\"id_af3_kft_byb\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr id=\"cdm_apps-stat-error\"><td>\n\nerror\n\n</td><td>\n\nIf an error occurred during processing, the details about the error.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr id=\"cdm_apps-stat-error_detail-row\"><td>\n\nerror.detail\n\n</td><td>\n\nAdditional information about the error.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_messaage-row\"><td>\n\nerror.message\n\n</td><td>\n\nError message that was generated while trying to process the request.Data type: String\n\n</td></tr><tr id=\"cdm_apps-stat-error_status-row\"><td>\n\nstatus\n\n</td><td>\n\nError status of the request.Possible values: failure\n\nData type: String\n\n</td></tr><tr id=\"cdm_apps-upload_id-row\"><td>\n\nupload\\_id\n\n</td><td>\n\nSys\\_id of the upload request. Use this ID to call the [CdmApplicationsApi - GET /sn\\_cdm/applications/upload-status/\\{upload\\_id\\}](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-apis/applications-api.md) endpoint to obtain the status of the upload.Data type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following request uploads a plain text file to the deployables folder of the CDM application.\n\n```\ncurl \"http://instance.servicenow.com/api/sn_cdm/applications/uploads/deployables/file?autoValidate=true&deployableName=depA&appName=testApp&namePath=testComponent%2FfilesFolder&fileName=testFileNodeName.txt&publishOption=publish_valid&changesetNumber=Chset-108&autoCommit=true&fileNodeName=testFile.txt\" \\ \n--request POST \\ \n--header \"Accept:application/json\" \\ \n--header \"Content-Type:text/plain\" \\ \n--data \"This is sample content that will be uploaded to a plain text file.\"\\ \n--user 'username':'password' \n\n```\n\nThe following return results show both a successful and an error response to this request.\n\n```\n// Successful completion of the upload request\n{ \n  \"result\": { \n    \"upload_id\": \"ec1f71f45322301096edddeeff7b12b3\" \n  } \n} \n\n// Error response. Payload is too large.\n{ \n  \"error\": { \n    \"message\": \"Could not find active application with name: ‘testApp’ of type application\", \n    \"detail\": \"\" \n  },\n  \"status\": \"failure\"\n}\n\n```\n\n## CdmApplicationsApi - PUT /sn\\_cdm/applications/deployables\n\nUpdates the specified shared component in an application within a specified changeset.\n\nAllows an update to the following fields:\n\n-   Name\n-   Description\n-   Application Service\\\\Dynamic CI Group\n-   Deployable identifier\n\nThe CDM Admin role is required to access this endpoint.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/deployables`\n\nDefault URL: `/api/sn_cdm/applications/deployables`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td>\n\nOptional. Version of the endpoint to access. For example, v1 or v2. Only specify this value to use an endpoint version other than the latest.Data type: String\n\n</td></tr></tbody>\n</table><table class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nappName\n\n</td><td>\n\nRequired. Name of the CDM Application.Data type: String\n\n</td></tr><tr><td>\n\nname\n\n</td><td>\n\nRequired. Name of the CDM Deployable.Data type: String\n\n</td></tr><tr><td>\n\nnewDescription\n\n</td><td>\n\nOptional. A description for the CDM Deployable.Data type: String\n\n</td></tr><tr><td>\n\nnewServiceId\n\n</td><td>\n\nOptional. The ID of the desired Application Service/Dynamic CI Group. In the cURL request, provide `'’` to disconnect the Deployable from the service.\n\n</td></tr><tr><td>\n\nnewIdentifier\n\n</td><td>\n\nOptional. The identifier of the Deployable.Data type: Choice \\(Development/Test/Production\n\n</td></tr><tr><td>\n\nnewName\n\n</td><td>\n\nOptional. The new name of the Deployable.Data type: String\n\n</td></tr><tr><td>\n\nreturnFields\n\n</td><td>\n\nOptional. Comma-separated list of fields to be returned as part of the response.\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Header|Description|\n|------|-----------|\n|Accept|Data format of the response body. Supported types: application/json|\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Status code|Description|\n|-----------|-----------|\n|200|Successful. The request was successfully processed.|\n|400|Bad request. A bad request type or malformed request was detected.|\n|500|Internal Server Error. An unexpected error occurred while processing the request. The response contains additional information about the error.|\n\n### Response body parameters \\(JSON or XML\\)\n\n<table><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nsys\\_id\n\n</td><td>\n\nCDM deployable sys\\_Id.\n\n</td></tr><tr><td>\n\nname\n\n</td><td>\n\nName of the CDM Deployable.\n\n</td></tr><tr><td>\n\nnode\n\n</td><td>\n\nDeployable node object.`{ ‘value’: ‘<sysId>’, ‘link’: ‘http://localhost:8081/api/now/table/*’}`\n\n</td></tr><tr><td>\n\ndescription\n\n</td><td>\n\nCDM deployable description.\n\n</td></tr><tr><td>\n\nidentifier\n\n</td><td>\n\nAn identifier for the deployable.\n\n</td></tr><tr><td>\n\ncmdb\\_ci\n\n</td><td>\n\nThe app service object which is connected to a deployable.`{ ‘value’: ‘<sysId>’, ‘link’: ‘http://localhost:8081/api/now/table/*’}`\n\n</td></tr><tr><td>\n\ncmdb\\_app\n\n</td><td>\n\nThe CDM application object.`{ ‘value’: ‘<sysId>’, ‘link’: ‘http://localhost:8081/api/now/table/*’}`\n\n</td></tr><tr><td>\n\nsnapshot\\_version\\_counter\n\n</td><td>\n\nThe count of snapshots created for a deployable.\n\n</td></tr><tr><td>\n\ncdi\\_count\n\n</td><td>\n\nThe number of CDIs contained in this CDM deployable.\n\n</td></tr><tr><td>\n\ncdi\\_usage\n\n</td><td>\n\nThe CDI usage percentage.\n\n</td></tr><tr><td>\n\nenvironment\\_type\n\n</td><td>\n\nThe environment type. Possible values: -   development\n-   production\n-   test\n\n</td></tr><tr><td>\n\nstate\n\n</td><td>\n\nThe active or deleted state . Possible values: -   active\n-   deleted\n\n</td></tr><tr><td>\n\nsys\\_created\\_by\n\n</td><td>\n\nCDM deployable created by &lt;username&gt;.\n\n</td></tr><tr><td>\n\nsys\\_created\\_on\n\n</td><td>\n\nCDM deployable creation timestamp in the format of &lt;yyyy-MM-dd hh:mm:ss&gt;.\n\n</td></tr><tr><td>\n\nsys\\_updated\\_by\n\n</td><td>\n\nCDM deployable updated by &lt;username&gt;.\n\n</td></tr><tr><td>\n\nsys\\_updated\\_on\n\n</td><td>\n\nCDM deployable updated by timestamp in the format of &lt;yyyy-MM-dd hh:mm:ss&gt;.\n\n</td></tr></tbody>\n</table>### cURL request\n\n```\ncurl \"http://localhost:8080/api/sn_cdm/applications/deployables?appName=testApp&name=Dep-1\" \\ \n--request PUT\\ \n--header \"Accept:application/json\" \\ \n--user 'cdm_admin':'password1!' \n```\n\nOutput:\n\n```\n{ \n  \"result\": { \n    \"identifier\": \"identiy1\", \n    \"cmdb_ci\": { \n      \"value\": \"f5b9e00b53901110a1d3ddeeff7b12b8\", \n      \"link\": \"http://192.168.0.233:8080/api/now/table/cmdb_ci_service_auto/f5b9e00b53901110a1d3ddeeff7b12b8\" \n    }, \n    \"cdi_count\": \"3\", \n    \"snapshot_version_counter\": \"1\", \n    \"description\": \"cdcds\", \n    \"sys_updated_on\": \"2022-07-27 13:40:13\", \n    \"environment_type\": \"Test\", \n    \"node\": { \n      \"value\": \"30c00d4053015110a1d3ddeeff7b12bf\", \n      \"link\": \"http://192.168.0.233:8080/api/now/table/sn_cdm_node/30c00d4053015110a1d3ddeeff7b12bf\" \n    }, \n    \"sys_id\": \"39b9e00b53901110a1d3ddeeff7b12b7\", \n    \"sys_updated_by\": \"admin\", \n    \"cdm_app\": { \n      \"value\": \"62b517a953b70110a1d3ddeeff7b128c\", \n      \"link\": \"http://192.168.0.233:8080/api/now/table/sn_cdm_application/62b517a953b70110a1d3ddeeff7b128c\" \n    }, \n    \"sys_created_on\": \"2022-06-29 12:53:57\", \n    \"cdi_usage\": \"0.03\", \n    \"name\": \"Dep-2\", \n    \"state\": \"active\", \n    \"sys_created_by\": \"admin\" \n  } \n} \n```\n\n## CdmApplicationsApi - PUT /sn\\_cdm/applications/shared\\_components\n\nUpdates the specified shared component in an application within a specified changeset.\n\nThe CDM Admin role is required to access this endpoint.\n\n### URL format\n\nVersioned URL: `/api/sn_cdm/{api_version}/applications/shared_components`\n\nDefault URL: `/api/sn_cdm/applications/shared_components`\n\n**Note:** Available versions are specified in the [REST API Explorer](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/use-REST-API-Explorer.md). For scripted REST APIs there is additional version information on the [Scripted REST Service form](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_CustomWebServices.md).\n\n### Supported request parameters\n\n<table class=\"rest_api_path_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\napi\\_version\n\n</td><td id=\"version-entry-RESTAPI\">\n\nOptional. Version of the endpoint to access. For example, `v1` or `v2`. Only specify this value to use an endpoint version other than the latest. Data type: String\n\n</td></tr></tbody>\n</table><table class=\"rest_api_query_parameters\"><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nchangesetNumber\n\n</td><td>\n\nRequired. Unique identifier of the changeset associated with the component.Data type: String\n\n</td></tr><tr><td>\n\nreturnFields\n\n</td><td id=\"cdm_apps-returnFields-entry\">\n\nList of fields to return as part of the response. Pass the record column names such as sys\\_id, sys\\_updated\\_by, or state.Data type: Array\n\nDefault: All fields as determined by the endpoint\n\n</td></tr><tr><td>\n\nsharedComponentName\n\n</td><td>\n\nRequired. Name of the shared component associated with the specified application.Data type: String\n\nTable: CDM Shared Component \\[sn\\_cdm\\_shared\\_component\\]\n\n</td></tr><tr><td>\n\nsharedLibraryName\n\n</td><td>\n\nRequired. Name of the shared library under which the component resides. The shared library must have the following fields defined as follows:-   state = active\n-   available = true\n-   type = shared\\_library\n\nData type: String\n\nTable: CDM Application \\[sn\\_cdm\\_application\\]\n\n</td></tr><tr><td>\n\nversion\n\n</td><td>\n\nRequired. Version name associated with the shared component.Data type: String\n\nTable: CDM Snapshot \\[sn\\_cdm\\_snapshot\\]\n\n</td></tr></tbody>\n</table>|Name|Description|\n|----|-----------|\n|None| |\n\n### Headers\n\nThe following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see [Supported REST API headers](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n<table class=\"rest_api_request_headers\"><thead><tr><th>\n\nHeader\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nAccept\n\n</td><td id=\"accept-entry-RESTAPI\">\n\nData format of the response body. Supported types: **application/json** or **application/xml**. Default: **application/json**\n\n</td></tr></tbody>\n</table>|Header|Description|\n|------|-----------|\n|None| |\n\n### Status codes\n\nThe following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see [REST API HTTP response codes](https://raw.githubusercontent.com/ServiceNow/ServiceNowDocs/australia/markdown/australia/api-reference/rest-api-explorer/c_RESTAPI.md).\n\n|Status code|Description|\n|-----------|-----------|\n|200|Successful. The request was successfully processed.|\n|400|Bad Request. The passed changeset does not exist.|\n|500|Internal server error. An unexpected error occurred while processing the request. The response contains additional information about the error.|\n\n### Response body parameters\n\nThe response fields depend on what fields were specified in the **returnFields** parameter in the request. The following describes some of the more important fields.\n\n<table><thead><tr><th>\n\nName\n\n</th><th>\n\nDescription\n\n</th></tr></thead><tbody><tr><td>\n\nchangeset\\_id\n\n</td><td id=\"changeset-node-editor-entry\">\n\nDetails of the changeset record associated with the node. Data type: Object\n\n```\n\"changeset_id\": {\n  \"link\": \"String\",\n  \"value\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\nchangeset\\_id.link\n\n</td><td id=\"changeset_link-node-editor-entry\">\n\nCall syntax for querying this changeset record using the Table REST API.Data type: String\n\n</td></tr><tr><td>\n\nchangeset\\_id.value\n\n</td><td id=\"changeset_value-node-editor-entry\">\n\nUnique identifier of the changeset record.Data type: String\n\nTable: CDM Changeset \\[sn\\_cdm\\_changeset\\]\n\n</td></tr><tr><td>\n\ndescription\n\n</td><td>\n\nDescription of the CDM node.Data type: String\n\n</td></tr><tr><td>\n\nerror\n\n</td><td id=\"cdm_apps-error-entry\">\n\nOnly returned if an error occurred during processing.Data type: Object\n\n```\n\"error\": {\n  \"detail\": \"String\",\n  \"message\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\nerror.detail\n\n</td><td id=\"cdm_apps-error_detail-entry\">\n\nDetails about the error that occurred.Data type: String\n\n</td></tr><tr><td>\n\nerror.message\n\n</td><td id=\"cdm_apps-error_message-entry\">\n\nMessage that provides an overview of the error.Data type: String\n\n</td></tr><tr><td>\n\nlinked\\_to\n\n</td><td>\n\nID of the main node associated with the shared component.Data type: String\n\n</td></tr><tr><td>\n\nlinked\\_to\\_version\n\n</td><td>\n\nDetails of the CDM snapshot record associated with the node. Data type: Object\n\n ```\n\"linked_to_version\": {\n  \"link\": \"String\",\n  \"value\": \"String\"\n}\n```\n\n</td></tr><tr><td>\n\nlinked\\_to\\_version.link\n\n</td><td>\n\nCall syntax for querying this version record using the Table REST API.Data type: String\n\n</td></tr><tr><td>\n\nlinked\\_to\\_version.value\n\n</td><td>\n\nSys\\_id of the version record.Data type: String\n\n</td></tr><tr><td>\n\nmain\n\n</td><td>\n\nFlag that indicates whether the associated snapshot was published.\n\n Valid values:\n\n-   true: Snapshot was published.\n-   false: Snapshot was not published.\n\n</td></tr><tr><td>\n\nmain\\_id\n\n</td><td>\n\nUnique ID of the newly created main node.Data type: String\n\n</td></tr><tr><td>\n\nmain\\_id\\_encoded\n\n</td><td>\n\nEncoded ID of the newly created main node.Data type: String\n\n</td></tr><tr><td>\n\nname\n\n</td><td>\n\nName of the CDM node.Data type: String\n\n</td></tr><tr><td>\n\nnode\n\n</td><td>\n\nSys\\_id of the shared component node.Data type: String\n\n</td></tr><tr><td>\n\nnode\\_path\n\n</td><td>\n\nPath to the new linked node created when adding the shared component. Data type: String\n\n</td></tr><tr><td>\n\nstatus\n\n</td><td>\n\nStatus of the node.Possible values: New\n\n Data type: String\n\n</td></tr><tr id=\"cdm_dep-sys_created_by-row\"><td>\n\nsys\\_created\\_by\n\n</td><td>\n\nUser name of the user that create the CDM node. For example, able.tuter.Data type: String\n\n</td></tr><tr id=\"cdm_deps-sys_created_on-row\"><td>\n\nsys\\_created\\_on\n\n</td><td>\n\nDate and time when the CDM node was created.Format: YYYY-mm-DD hh:mm:ss\n\n Data type: String\n\n</td></tr><tr><td>\n\nsys\\_id\n\n</td><td id=\"sys_id-node-editor-entry\">\n\nSys\\_id of the node.Data type: String\n\nTable: CDM Node \\[sn\\_cdm\\_node\\]\n\n</td></tr><tr id=\"cdm_dep-sys_updated_by-row\"><td>\n\nsys\\_updated\\_by\n\n</td><td>\n\nUser name of the user that last updated the CDM node. For example, able.tuter.Data type: String\n\n</td></tr><tr id=\"cdm_dep-sys_updated_on-row\"><td>\n\nsys\\_updated\\_on\n\n</td><td>\n\nDate and time when the CDM node was last updated.Format: YYYY-mm-DD hh:mm:ss\n\n Data type: String\n\n</td></tr><tr><td>\n\ntype\n\n</td><td>\n\nNode type.Data type: String\n\n</td></tr></tbody>\n</table>### cURL request\n\nThe following example shows how to call this endpoint to update the application \"App1\" with the shared component \"paymentService-V1.1\" under the shared library \"OracleG-Library-10\" within the \"Chset-20\" changeset.\n\n```\n\"https://instance-name.service-now.com/api/sn_cdm/applications/shared_components?sharedComponentName=paymentService-V1.1&sharedLibraryName=OracleG-Library-10&changesetNumber=Chset-20&versionName=sComp3-v2.shc&appName=App1\" \\ \n--request PUT \\ \n--header \"Accept:application/json\" \\ \n--user 'username':'password'\n```\n\nResponse:\n\n```\n\"result\": {\n  \"changeset_id\": {\n    \"value\": \"7343d0f71b771110636e0fe0604bcb0b\",\n    \"link\": \"https://instance-name.service-now.com/api/now/table/sn_cdm_changeset/7343d0f71b771110636e0fe0604bcb0b\"\n  },\n  \"node_path\": \"!2!3!&`\",\n  \"description\": null,\n  \"sys_updated_on\": \"2022-12-22 18:52:38\",\n  \"type\": \"sn_cdm_node_linked_shared_component\",\n  \"sys_class_name\": \"sn_cdm_node\",\n  \"sys_id\": \"339314b71b771110636e0fe0604bcba3\",\n  \"sys_updated_by\": ”admin\",\n  \"previous_version\": {\n    \"value\": \"a9ce80bf1b371110636e0fe0604bcb10\",\n    \"link\": \"https://instance-name.service-now.com/api/now/table/sn_cdm_node/a9ce80bf1b371110636e0fe0604bcb10\" \n  },\n  \"sys_created_on\": \"2022-12-22 18:52:38\",\n  \"value\": null,\n  \"effective_from\": null,\n  \"linked_to\": \"146\", \n  \"sys_created_by\": ”admin\",\n  \"restricted_to\": null,\n  \"linked_to_version\": {\n    \"value\": \"54115c371b771110636e0fe0604bcb77\",\n    \"link\": \"https://instance-name.service-now.com/api/now/table/sn_cdm_snapshot/54115c371b771110636e0fe0604bcb77\"\n  },\n  \"level\": \"2\",\n  \"conflict_type\": null,\n  \"main_id\": \"166\",\n  \"effective_to\": null,\n  \"secure_value\": null,\n  \"node_classifier\": \"/application/components\",\n  \"main_id_encoded\": \"&`\",\n  \"name\": \"Component_A\",\n  \"position\": null,\n  \"reason_for_conflict\": null,\n  \"system_folder\": false,\n  \"status\": \"updated\",\n  \"conflict\": false\n} \n```\n\n"}}