Skip to main content

List targets

POST 

/v2beta/actions/targets/_search

List all matching targets. By default all targets of the instance are returned. Make sure to include a limit and sorting for pagination.

Required permission:

  • action.target.read

Required feature flag:

  • actions

Request​

Body

required

    pagination

    object

    List limitations and ordering.

    offset uint64

    Starting point for retrieval, in combination of offset used to query a set list of objects.

    limit int64

    limit is the maximum amount of objects returned. The default is set to 100 with a maximum of 1000 in the runtime configuration. If the limit exceeds the maximum configured ZITADEL will throw an error. If no limit is present the default is taken.

    asc boolean

    Asc is the sorting order. If true the list is sorted ascending, if false the list is sorted descending. The default is descending.

    sortingColumn string

    Possible values: [TARGET_FIELD_NAME_UNSPECIFIED, TARGET_FIELD_NAME_ID, TARGET_FIELD_NAME_CREATED_DATE, TARGET_FIELD_NAME_CHANGED_DATE, TARGET_FIELD_NAME_NAME, TARGET_FIELD_NAME_TARGET_TYPE, TARGET_FIELD_NAME_URL, TARGET_FIELD_NAME_TIMEOUT, TARGET_FIELD_NAME_INTERRUPT_ON_ERROR]

    Default value: "TARGET_FIELD_NAME_CREATION_DATE"

    The field the result is sorted by. The default is the creation date. Beware that if you change this, your result pagination might be inconsistent.

    filters

    object[]

    Define the criteria to query for.

  • Array [

  • targetNameFilter

    object

    targetName string

    Possible values: <= 200 characters

    Defines the name of the target to query for.

    method string

    Possible values: [TEXT_FILTER_METHOD_EQUALS, TEXT_FILTER_METHOD_EQUALS_IGNORE_CASE, TEXT_FILTER_METHOD_STARTS_WITH, TEXT_FILTER_METHOD_STARTS_WITH_IGNORE_CASE, TEXT_FILTER_METHOD_CONTAINS, TEXT_FILTER_METHOD_CONTAINS_IGNORE_CASE, TEXT_FILTER_METHOD_ENDS_WITH, TEXT_FILTER_METHOD_ENDS_WITH_IGNORE_CASE]

    Default value: TEXT_FILTER_METHOD_EQUALS

    defines which text equality method is used

    inTargetIdsFilter

    object

    targetIds string[]

    the ids of the targets to include

  • ]

Responses​

A list of all targets matching the query

Schema

    pagination

    object

    totalResult uint64

    Absolute number of objects matching the query, regardless of applied limit.

    appliedLimit uint64

    Applied limit from query, defines maximum amount of objects per request, to compare if all objects are returned.

    result

    object[]

  • Array [

  • id string

    The unique identifier of the target.

    creationDate date-time

    The timestamp of the target creation.

    changeDate date-time

    The timestamp of the last change to the target (e.g. creation, activation, deactivation).

    name string

    restWebhook

    object

    interruptOnError boolean

    Define if any error stops the whole execution. By default the process continues as normal.

    restCall

    object

    interruptOnError boolean

    Define if any error stops the whole execution. By default the process continues as normal.

    restAsync object
    timeout string

    Timeout defines the duration until ZITADEL cancels the execution. If the target doesn't respond before this timeout expires, the the connection is closed and the action fails. Depending on the target type and possible setting on interrupt_on_error following targets will not be called. In case of a rest_async target only this specific target will fail, without any influence on other targets of the same execution.

    endpoint string
    signingKey string
  • ]

Loading...