Refresh batch of connections#

Description#

Refreshes multiple incoming connections within the same spreadsheet, based on ID. When connecting to multiple spreadsheets, tables or other destinations, use the singular refresh connection instead. usePreviousDestinationParameters and usePreviousSourceParameters will use the exact parameters of your previous run; any new parameters you’ve provided will be ignored. This endpoint only works for outgoing connections if they are all connected to the same workbook. This endpoint has a limit of 100 refreshes per request.

POST /api/v1/connections/batch/refresh

Required OAuth Scopes

No OAuth scopes are required to use this endpoint.

Parameters#

Parameter

In

Type

Required

Description

cancelUnwritables

query

boolean

false

Allow individual connections in the batch to be canceled if they have a destination that is unwritable. This will NOT cancel the entire batch.

Body parameter example#

[
  {
    "connectionId": "string",
    "destinationParameters": {
      "property1": null,
      "property2": null
    },
    "sourceParameters": {
      "property1": null,
      "property2": null
    },
    "usePreviousDestinationParameters": true,
    "usePreviousSourceParameters": true,
    "workspaceId": "string"
  }
]

Code Samples#

curl -X POST https://h.app.wdesk.com/s/wdata/prep/api/v1/connections/batch/refresh \
    -H 'Content-Type: application/json' \
    -H 'Accept: application/json' \
    -H 'Authorization: Bearer {access-token}'
http POST https://h.app.wdesk.com/s/wdata/prep/api/v1/connections/batch/refresh \
    Content-Type:application/json \
    Accept:application/json \
    Authorization:"Bearer {access-token}"
wget --method=POST "https://h.app.wdesk.com/s/wdata/prep/api/v1/connections/batch/refresh" \
    --output-document -  \ 
    --header 'Content-Type: application/json' \ 
    --header 'Accept: application/json' \ 
    --header 'Authorization: Bearer {access-token}'
import requests

headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://h.app.wdesk.com/s/wdata/prep/api/v1/connections/batch/refresh', headers = headers)

print(r.json())

Returns#

200 - OK#

undefined

Example Responses#

{
  "body": {
    "batchRefreshId": "string",
    "childRefreshes": [
      {
        "connectionId": "string",
        "created": "string",
        "createdBy": "string",
        "destinationMetadata": {},
        "destinationParameters": {},
        "destinationStatus": "string",
        "destinationWorkspaceId": "string",
        "error": "string",
        "jobId": "string",
        "sourceMetadata": {},
        "sourceParameters": {},
        "sourceStatus": "string",
        "sourceWorkspaceId": "string",
        "updated": "string",
        "workspaceId": "string"
      }
    ],
    "created": "string",
    "createdBy": "string",
    "destinationStatus": "string",
    "error": "string",
    "sourceStatus": "string",
    "updated": "string"
  },
  "code": "integer"
}