PUT
/
v1
/
datasources
/
{id}
# Example Request
curl -X PUT "https://api.getmetal.io/v1/datasources/{id}" \
--header 'Content-Type: application/json' \
--header 'x-metal-api-key: <api-key>' \
--header 'x-metal-client-id: <client-id>' \
--data-raw '{
  "name": "updated_datasource",
  "metadataFields": [
    {
      "name": "updated_field",
      "type": "string",
      "description": "Updated description"
    }
  ],
  "sourcetype": "updated_type",
  "autoExtract": false
}'
{
  "data": {
    "id": "datasourceID",
    "name": "updated_datasource",
    "metadataFields": [
      {
        "name": "updated_field",
        "type": "string",
        "description": "Updated description"
      }
    ],
    "sourcetype": "updated_type",
    "autoExtract": false,
    "updatedAt": "2023-03-17T17:21:13.163Z"
  }
}

Auth Headers

x-metal-api-key
string
required

An API key for your org.

x-metal-client-id
string
required

A Client ID for your org.

Params

id
string
required

The unique identifier of the Datasource you wish to update.

Body

name
string

Updated name of the Datasource.

metadataFields
array

An array of updated metadata fields, each having a name, type, and description.

sourcetype
string

Updated type of the Datasource.

autoExtract
boolean

Updated flag indicating whether auto-extraction is enabled or not.