ReferenceFor engineers

API calls & webhooks

Inspect the API calls and webhook calls a care flow makes, and retry failed ones.

Inspect the API calls and webhook calls a care flow makes, and retry failed ones.

Queries

apiCall

Fetches a single API call by its ID.

Arguments

ArgumentTypeRequiredDescription
idString!YesThe ID of the API call

Returns: ApiCallPayload!

Example

query ApiCall($id: String!) {
  apiCall(id: $id) {
    api_call {
      created_at
      id
      request {
        body
        endpoint
        method
      }
      responses {
        body
        date
        status
      }
      status
      title
    }
    code
    success
  }
}

Variables:

{
  "id": "<string>"
}

apiCalls

Lists the API calls made by a care flow.

Arguments

ArgumentTypeRequiredDescription
pathway_idString!YesThe ID of the care flow

Returns: ApiCallsPayload!

Example

query ApiCalls($pathway_id: String!) {
  apiCalls(pathway_id: $pathway_id) {
    api_calls {
      created_at
      id
      request {
        body
        endpoint
        method
      }
      responses {
        body
        date
        status
      }
      status
      title
    }
    code
    success
  }
}

Variables:

{
  "pathway_id": "<string>"
}

webhookCall

Fetches a single webhook call by its ID.

Arguments

ArgumentTypeRequiredDescription
webhook_call_idString!YesThe ID of the webhook call

Returns: WebhookCallPayload!

Example

query WebhookCall($webhook_call_id: String!) {
  webhookCall(webhook_call_id: $webhook_call_id) {
    code
    success
    webhook_call {
      created_at
      event_type
      id
      pathway {
        id
        pathway_definition_id
        patient_id
        start_date
      }
      request {
        body
        endpoint
        method
      }
      responses {
        body
        date
        status
      }
      status
      webhook_id
      webhook_name
    }
  }
}

Variables:

{
  "webhook_call_id": "<string>"
}

webhookCalls

Lists the webhook calls made by a care flow.

Arguments

ArgumentTypeRequiredDescription
filtersWebhookCallFiltersInputNoFilters to apply to the webhook calls
paginationPaginationParamsNoHow many results to return and the offset to start from — see Pagination
pathway_idString!YesThe ID of the care flow
sortingSortingParamsNoThe field to sort by and the sort direction — see Pagination

Returns: WebhookCallsPayload!

Example

query WebhookCalls($filters: WebhookCallFiltersInput, $pagination: PaginationParams, $pathway_id: String!, $sorting: SortingParams) {
  webhookCalls(filters: $filters, pagination: $pagination, pathway_id: $pathway_id, sorting: $sorting) {
    code
    pagination {
      count
      offset
      total_count
    }
    sorting {
      direction
      field
    }
    success
    webhook_calls {
      created_at
      event_type
      id
      pathway {
        id
        pathway_definition_id
        patient_id
        start_date
      }
      request {
        body
        endpoint
        method
      }
      responses {
        body
        date
        status
      }
      status
      webhook_id
      webhook_name
    }
  }
}

Variables:

{
  "filters": {},
  "pagination": {
    "count": 0,
    "offset": 0
  },
  "pathway_id": "<string>",
  "sorting": {
    "direction": "<string>",
    "field": "<string>"
  }
}

webhookCallsForPathwayDefinition

Lists the webhook calls made across all care flows of a care flow definition.

Arguments

ArgumentTypeRequiredDescription
filtersWebhookCallFiltersInputNoFilters to apply to the webhook calls
paginationPaginationParamsNoHow many results to return and the offset to start from — see Pagination
pathway_definition_idString!YesThe ID of the care flow definition
sortingSortingParamsNoThe field to sort by and the sort direction — see Pagination

Returns: WebhookCallsPayload!

Example

query WebhookCallsForPathwayDefinition($filters: WebhookCallFiltersInput, $pagination: PaginationParams, $pathway_definition_id: String!, $sorting: SortingParams) {
  webhookCallsForPathwayDefinition(filters: $filters, pagination: $pagination, pathway_definition_id: $pathway_definition_id, sorting: $sorting) {
    code
    pagination {
      count
      offset
      total_count
    }
    sorting {
      direction
      field
    }
    success
    webhook_calls {
      created_at
      event_type
      id
      pathway {
        id
        pathway_definition_id
        patient_id
        start_date
      }
      request {
        body
        endpoint
        method
      }
      responses {
        body
        date
        status
      }
      status
      webhook_id
      webhook_name
    }
  }
}

Variables:

{
  "filters": {},
  "pagination": {
    "count": 0,
    "offset": 0
  },
  "pathway_definition_id": "<string>",
  "sorting": {
    "direction": "<string>",
    "field": "<string>"
  }
}

webhookCallsForTenant

Lists the webhook calls made across the tenant.

Arguments

ArgumentTypeRequiredDescription
filtersWebhookCallFiltersInputNoFilters to apply to the webhook calls
paginationPaginationParamsNoHow many results to return and the offset to start from — see Pagination
sortingSortingParamsNoThe field to sort by and the sort direction — see Pagination

Returns: WebhookCallsPayload!

Example

query WebhookCallsForTenant($filters: WebhookCallFiltersInput, $pagination: PaginationParams, $sorting: SortingParams) {
  webhookCallsForTenant(filters: $filters, pagination: $pagination, sorting: $sorting) {
    code
    pagination {
      count
      offset
      total_count
    }
    sorting {
      direction
      field
    }
    success
    webhook_calls {
      created_at
      event_type
      id
      pathway {
        id
        pathway_definition_id
        patient_id
        start_date
      }
      request {
        body
        endpoint
        method
      }
      responses {
        body
        date
        status
      }
      status
      webhook_id
      webhook_name
    }
  }
}

Variables:

{
  "filters": {},
  "pagination": {
    "count": 0,
    "offset": 0
  },
  "sorting": {
    "direction": "<string>",
    "field": "<string>"
  }
}

Mutations

retryAllApiCalls

Retries all API calls for a care flow.

Arguments

ArgumentTypeRequiredDescription
inputRetryAllApiCallsInput!YesThe care flow whose API calls to retry

Returns: EmptyPayload!

Example

mutation RetryAllApiCalls($input: RetryAllApiCallsInput!) {
  retryAllApiCalls(input: $input) {
    code
    success
  }
}

Variables:

{
  "input": {
    "pathway_id": "<string>"
  }
}

retryAllFailedApiCalls

Retries all failed API calls for a care flow.

Arguments

ArgumentTypeRequiredDescription
inputRetryAllFailedApiCallsInput!YesThe care flow whose failed API calls to retry

Returns: EmptyPayload!

Example

mutation RetryAllFailedApiCalls($input: RetryAllFailedApiCallsInput!) {
  retryAllFailedApiCalls(input: $input) {
    code
    success
  }
}

Variables:

{
  "input": {
    "pathway_id": "<string>"
  }
}

retryAllFailedWebhookCalls

Retries all failed webhook calls for a care flow.

Arguments

ArgumentTypeRequiredDescription
inputRetryAllFailedWebhookCallsInput!YesThe care flow whose failed webhook calls to retry

Returns: EmptyPayload!

Example

mutation RetryAllFailedWebhookCalls($input: RetryAllFailedWebhookCallsInput!) {
  retryAllFailedWebhookCalls(input: $input) {
    code
    success
  }
}

Variables:

{
  "input": {
    "pathway_id": "<string>"
  }
}

retryAllFailedWebhookCallsForPathwayDefinition

Retries all failed webhook calls across all care flows of a care flow definition.

Arguments

ArgumentTypeRequiredDescription
inputRetryAllFailedWebhookCallsForPathwayDefinitionInput!YesThe care flow definition whose failed webhook calls to retry

Returns: EmptyPayload!

Example

mutation RetryAllFailedWebhookCallsForPathwayDefinition($input: RetryAllFailedWebhookCallsForPathwayDefinitionInput!) {
  retryAllFailedWebhookCallsForPathwayDefinition(input: $input) {
    code
    success
  }
}

Variables:

{
  "input": {
    "pathway_definition_id": "<string>"
  }
}

retryAllWebhookCalls

Retries all webhook calls for a care flow.

Arguments

ArgumentTypeRequiredDescription
inputRetryAllWebhookCallsInput!YesThe care flow whose webhook calls to retry

Returns: EmptyPayload!

Example

mutation RetryAllWebhookCalls($input: RetryAllWebhookCallsInput!) {
  retryAllWebhookCalls(input: $input) {
    code
    success
  }
}

Variables:

{
  "input": {
    "pathway_id": "<string>"
  }
}

retryApiCall

Retries a single API call.

Arguments

ArgumentTypeRequiredDescription
inputRetryApiCallInput!YesThe API call to retry

Returns: RetryApiCallPayload!

Example

mutation RetryApiCall($input: RetryApiCallInput!) {
  retryApiCall(input: $input) {
    api_call {
      created_at
      id
      request {
        body
        endpoint
        method
      }
      responses {
        body
        date
        status
      }
      status
      title
    }
    code
    success
  }
}

Variables:

{
  "input": {
    "api_call_id": "<string>"
  }
}

retryPushToEmr

Retries pushing an activity's data to the EMR.

Arguments

ArgumentTypeRequiredDescription
inputRetryPushToEmrInput!YesThe activity whose push to the EMR to retry

Returns: EmptyPayload!

Example

mutation RetryPushToEmr($input: RetryPushToEmrInput!) {
  retryPushToEmr(input: $input) {
    code
    success
  }
}

Variables:

{
  "input": {
    "activity_id": "<string>"
  }
}

retryWebhookCall

Retries a single webhook call.

Arguments

ArgumentTypeRequiredDescription
inputRetryWebhookCallInput!YesThe webhook call to retry

Returns: RetryWebhookCallPayload!

Example

mutation RetryWebhookCall($input: RetryWebhookCallInput!) {
  retryWebhookCall(input: $input) {
    code
    success
    webhook_call {
      created_at
      event_type
      id
      pathway {
        id
        pathway_definition_id
        patient_id
        start_date
      }
      request {
        body
        endpoint
        method
      }
      responses {
        body
        date
        status
      }
      status
      webhook_id
      webhook_name
    }
  }
}

Variables:

{
  "input": {
    "webhook_call_id": "<string>"
  }
}

On this page