Publishers - Query Publishers

Query for service hook publishers.

POST https://dev.azure.com/{organization}/_apis/hooks/publishersquery?api-version=7.1

URI Parameters

Name In Required Type Description
organization
path True

string

The name of the Azure DevOps organization.

api-version
query True

string

Version of the API to use. This should be set to '7.1' to use this version of the api.

Request Body

Name Type Description
publisherIds

string[]

Optional list of publisher ids to restrict the results to

publisherInputs

object

Filter for publisher inputs

results

Publisher[]

Results from the query

Responses

Name Type Description
200 OK

PublishersQuery

successful operation

Security

oauth2

Type: oauth2
Flow: accessCode
Authorization URL: https://app.vssps.visualstudio.com/oauth2/authorize&response_type=Assertion
Token URL: https://app.vssps.visualstudio.com/oauth2/token?client_assertion_type=urn:ietf:params:oauth:client-assertion-type:jwt-bearer&grant_type=urn:ietf:params:oauth:grant-type:jwt-bearer

Scopes

Name Description
vso.work Grants the ability to read work items, queries, boards, area and iterations paths, and other work item tracking related metadata. Also grants the ability to execute queries, search work items and to receive notifications about work item events via service hooks.
vso.build Grants the ability to access build artifacts, including build results, definitions, and requests, and the ability to receive notifications about build events via service hooks.
vso.code Grants the ability to read source code and metadata about commits, changesets, branches, and other version control artifacts. Also grants the ability to search code and get notified about version control events via service hooks.

Definitions

Name Description
EventTypeDescriptor

Describes a type of event

InputDataType

Gets or sets the data type to validate.

InputDescriptor

Describes an input for subscriptions.

InputMode

Mode in which the value of this input should be entered

InputValidation

Describes what values are valid for a subscription input

InputValue

Information about a single value for an input

InputValues

Information about the possible/allowed values for a given subscription input

InputValuesError

Error information related to a subscription input value.

Publisher

Defines the data contract of an event publisher.

PublishersQuery

Defines a query for service hook publishers.

ReferenceLinks

The class to represent a collection of REST reference links.

EventTypeDescriptor

Describes a type of event

Name Type Description
description

string

A localized description of the event type

id

string

A unique id for the event type

inputDescriptors

InputDescriptor[]

Event-specific inputs

name

string

A localized friendly name for the event type

publisherId

string

A unique id for the publisher of this event type

supportedResourceVersions

string[]

Supported versions for the event's resource payloads.

url

string

The url for this resource

InputDataType

Gets or sets the data type to validate.

Name Type Description
boolean

string

Represents a value of true or false.

guid

string

Represents a Guid.

none

string

No data type is specified.

number

string

Represents a numeric value.

string

string

Represents a textual value.

uri

string

Represents a URI.

InputDescriptor

Describes an input for subscriptions.

Name Type Description
dependencyInputIds

string[]

The ids of all inputs that the value of this input is dependent on.

description

string

Description of what this input is used for

groupName

string

The group localized name to which this input belongs and can be shown as a header for the container that will include all the inputs in the group.

hasDynamicValueInformation

boolean

If true, the value information for this input is dynamic and should be fetched when the value of dependency inputs change.

id

string

Identifier for the subscription input

inputMode

InputMode

Mode in which the value of this input should be entered

isConfidential

boolean

Gets whether this input is confidential, such as for a password or application key

name

string

Localized name which can be shown as a label for the subscription input

properties

object

Custom properties for the input which can be used by the service provider

type

string

Underlying data type for the input value. When this value is specified, InputMode, Validation and Values are optional.

useInDefaultDescription

boolean

Gets whether this input is included in the default generated action description.

validation

InputValidation

Information to use to validate this input's value

valueHint

string

A hint for input value. It can be used in the UI as the input placeholder.

values

InputValues

Information about possible values for this input

InputMode

Mode in which the value of this input should be entered

Name Type Description
checkBox

string

Checkbox should be shown(for true/false values)

combo

string

A select/combo control should be shown

none

string

This input should not be shown in the UI

passwordBox

string

An password input box should be shown

radioButtons

string

Radio buttons should be shown

textArea

string

A multi-line text area should be shown

textBox

string

An input text box should be shown

InputValidation

Describes what values are valid for a subscription input

Name Type Description
dataType

InputDataType

Gets or sets the data type to validate.

isRequired

boolean

Gets or sets if this is a required field.

maxLength

integer

Gets or sets the maximum length of this descriptor.

maxValue

string

Gets or sets the minimum value for this descriptor.

minLength

integer

Gets or sets the minimum length of this descriptor.

minValue

string

Gets or sets the minimum value for this descriptor.

pattern

string

Gets or sets the pattern to validate.

patternMismatchErrorMessage

string

Gets or sets the error on pattern mismatch.

InputValue

Information about a single value for an input

Name Type Description
data

object

Any other data about this input

displayValue

string

The text to show for the display of this value

value

string

The value to store for this input

InputValues

Information about the possible/allowed values for a given subscription input

Name Type Description
defaultValue

string

The default value to use for this input

error

InputValuesError

Errors encountered while computing dynamic values.

inputId

string

The id of the input

isDisabled

boolean

Should this input be disabled

isLimitedToPossibleValues

boolean

Should the value be restricted to one of the values in the PossibleValues (True) or are the values in PossibleValues just a suggestion (False)

isReadOnly

boolean

Should this input be made read-only

possibleValues

InputValue[]

Possible values that this input can take

InputValuesError

Error information related to a subscription input value.

Name Type Description
message

string

The error message.

Publisher

Defines the data contract of an event publisher.

Name Type Description
_links

ReferenceLinks

Reference Links

description

string

Gets this publisher's localized description.

id

string

Gets this publisher's identifier.

inputDescriptors

InputDescriptor[]

Publisher-specific inputs

name

string

Gets this publisher's localized name.

serviceInstanceType

string

The service instance type of the first party publisher.

supportedEvents

EventTypeDescriptor[]

Gets this publisher's supported event types.

url

string

The url for this resource

PublishersQuery

Defines a query for service hook publishers.

Name Type Description
publisherIds

string[]

Optional list of publisher ids to restrict the results to

publisherInputs

object

Filter for publisher inputs

results

Publisher[]

Results from the query

The class to represent a collection of REST reference links.

Name Type Description
links

object

The readonly view of the links. Because Reference links are readonly, we only want to expose them as read only.