PATCH
/
sources
/
{source_id}
curl --request PATCH \
  --url https://app.getcensus.com/api/v1/sources/{source_id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "connection": {
    "credentials": {
      "database": "demo",
      "hostname": "<instance>.<region>.redshift.amazonaws.com,",
      "password": "redshift_password,",
      "port": "5439,",
      "user": "redshift_user,"
    },
    "label": "Acme Inc. Snowflake"
  }
}'
{
  "data": {
    "connection_details": {
      "account": "xxxxxxx.us-east-1,",
      "use_keypair": false,
      "user": "DEV,",
      "warehouse": "TEST,"
    },
    "id": 4,
    "label": "Acme Inc. Snowflake",
    "last_test_succeeded": true,
    "last_tested_at": "2023-11-07T05:31:56Z",
    "name": "Snowflake - xxxxxxx.us-east-1",
    "type": [
      "snowflake",
      "redshift",
      "big_query"
    ]
  },
  "status": "updated"
}

Authorizations

Authorization
string
headerrequired

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

source_id
integer
required

ID of the source to update

Body

application/json
connection
object

Contains the information for the connection.

Response

200 - application/json
data
object
status
enum<string>

Outcome of the operation.

Available options:
success,
updated,
created,
not_found,
error