Azure Batch

Azure Batch

Certified

Run transactional batch creates

Executes a single-partition transactional batch of item creates; all operations share one partition key value and succeed or fail together.

yaml
type: io.kestra.plugin.azure.storage.cosmosdb.Batch
yaml
id: azure_cosmos_container_batch_create_item
namespace: company.team

tasks:
  - id: batch_create
    type: io.kestra.plugin.azure.storage.cosmosdb.Batch
    endpoint: "https://yourcosmosaccount.documents.azure.com"
    databaseId: your_data_base_id
    containerId: your_container_id
    partitionKeyValue: europe
    tenantId: "{{ secret('AZURE_TENANT_ID') }}"
    clientId: "{{ secret('AZURE_CLIENT_ID') }}"
    clientSecret: "{{ secret('AZURE_CLIENT_SECRET') }}"
    items:
        - id: item_one
          region: europe
          key: value
        - id: item_two
          region: europe
          key: value
Properties

Container ID

Container (collection) name within the database; must already exist.

Database ID

Target database name inside the account; required.

SubTypeobject

Documents to create

List of JSON documents; each must include the partition key field matching partitionKeyValue.

Partition key value for batch

Value common to every item (e.g. "US" for a /country key); batch cannot span partitions.

Azure AD tenant ID (GUID)

Client ID of the Azure AD application

Application (client) ID used for service principal authentication.

Client secret for the Azure AD application

Secret value associated with the client ID; store in a Kestra secret.

Cosmos connection string

Full connection string from Azure portal; overrides endpoint and Azure AD credentials when set.

DefaultSession
Possible Values
STRONGBOUNDED_STALENESSSESSIONEVENTUALCONSISTENT_PREFIX

Choose request consistency

Consistency level sent to Cosmos; defaults to SESSION.

Defaulttrue

Return payload on writes

When true (default), write responses include the document body; set false to reduce payload size.

Cosmos account endpoint

Base account URL (e.g. https://.documents.azure.com). Required when connectionString is absent.

PEM-encoded certificate content for client authentication

PEM text for certificate-based auth; alternative to clientSecret.

Reference (ref) of the pluginDefaults to apply to this task.

Activity id

Diagnostics

Definitions
feedResponseDiagnostics
clientSideRequestStatisticsarray
activityIdstring
addressResolutionStatisticsobject
contactedReplicasarray
SubTypestring
diagnosticsClientConfig
failedReplicasarray
SubTypestring
gatewayStatisticsListarray
locationEndpointsContactedarray
SubTypestring
metadataDiagnosticsContext
regionsContactedarray
SubTypestring
requestEndTimeUTCstring
Formatdate-time
requestPayloadSizeInBytesinteger
requestStartTimeUTCstring
Formatdate-time
responseStatisticsListarray
retryContext
samplingRateSnapshotnumber
serializationDiagnosticsContext
supplementalResponseStatisticsListarray
diagnosticsContext
endTimeUTCstring
Formatdate-time
requestTimeline
startTimeUTCstring
Formatdate-time
queryMetricsMapobject
clientSideMetrics
documentLoadTimestring
Formatduration
documentWriteTimestring
Formatduration
indexHitDocumentCountinteger
indexLookupTimestring
Formatduration
indexUtilizationInfo
outputDocumentCountinteger
outputDocumentSizeinteger
queryPreparationTimes
retrievedDocumentCountinteger
retrievedDocumentSizeinteger
runtimeExecutionTimes
totalQueryExecutionTimestring
Formatduration
samplingRateSnapshotnumber
Formatduration

Duration

Error message

Request charge

SubTypestring

Response headers

Response length

Results

Definitions
effectiveItemSerializer
canSerializeboolean
shouldWrapSerializationExceptionsboolean
requestChargenumber
statusCodeinteger
subStatusCodeinteger
Formatduration

Retry after duration

Session token

Status code

Sub status code

Success status code