Adobe · Arazzo Workflow

Adobe Inspect PDF Properties

Version 1.0.0

Upload a PDF, request its metadata properties, and poll the job until done or failed.

1 workflow 1 source API 1 provider
View Spec View on GitHub AnalyticsCreative CloudDigital Asset ManagementDocument ServicesE-CommerceE-SignaturesExperience CloudGenerative AIMarketingPDFWork ManagementArazzoWorkflows

Provider

adobe

Workflows

inspect-pdf-properties
Retrieve metadata properties for an uploaded PDF.
Requests an upload slot for the source PDF, submits a getPDFProperties job with page-level properties enabled, polls job status until it reaches a terminal state, and branches to report success or failure of the inspection.
5 steps inputs: accessToken, includePageLevelProperties, jobID outputs: downloadUri, failureMessage, propertiesAssetID, sourceAssetID
1
requestUpload
uploadAsset
Request a pre-signed upload URI and asset ID for the source PDF, which is then PUT to the returned uploadUri out of band.
2
submitProperties
getPDFProperties
Submit an asynchronous getPDFProperties job that inspects the uploaded PDF's metadata. Returns 201 with an in-progress job status.
3
pollStatus
getJobStatus
Poll the getPDFProperties job until it reaches a terminal state. Loops back while the status is "in progress", branches to a success report when "done", and to a failure report when "failed".
4
reportSuccess
getAsset
Resolve a download URI for the properties output asset produced by a successful inspection job.
5
reportFailure
getJobStatus
Re-read the job status to capture the error code and message when the inspection job failed, ending the workflow with the failure recorded.

Source API Descriptions

Arazzo Workflow Specification

adobe-inspect-pdf-properties-workflow.yml Raw ↑
arazzo: 1.0.1
info:
  title: Adobe Inspect PDF Properties
  summary: Upload a PDF, request its metadata properties, and poll the job until done or failed.
  description: >-
    Drives the Adobe PDF Services asynchronous PDF-properties pipeline that
    reports a PDF's metadata such as page count, page size, encryption state,
    and PDF/A compliance. The workflow registers the source PDF by requesting a
    pre-signed upload URI and asset ID, submits a getPDFProperties job
    requesting page-level detail, then polls the job and branches on the
    terminal status: a done result exposes the output properties asset, while a
    failed result surfaces the error. Each step spells out its request inline.
    The polling job identifier is supplied as a workflow input because the
    submit response exposes only an opaque Location header.
  version: 1.0.0
sourceDescriptions:
- name: pdfServicesApi
  url: ../openapi/adobe-pdf-services-api-openapi.yml
  type: openapi
workflows:
- workflowId: inspect-pdf-properties
  summary: Retrieve metadata properties for an uploaded PDF.
  description: >-
    Requests an upload slot for the source PDF, submits a getPDFProperties job
    with page-level properties enabled, polls job status until it reaches a
    terminal state, and branches to report success or failure of the
    inspection.
  inputs:
    type: object
    required:
    - accessToken
    - jobID
    properties:
      accessToken:
        type: string
        description: OAuth 2.0 bearer access token from Adobe IMS.
      includePageLevelProperties:
        type: boolean
        description: Whether to include page-level property details.
        default: true
      jobID:
        type: string
        description: The job identifier taken from the getPDFProperties response Location header, used to poll status.
  steps:
  - stepId: requestUpload
    description: >-
      Request a pre-signed upload URI and asset ID for the source PDF, which is
      then PUT to the returned uploadUri out of band.
    operationId: uploadAsset
    parameters:
    - name: Authorization
      in: header
      value: "Bearer $inputs.accessToken"
    requestBody:
      contentType: application/json
      payload:
        mediaType: application/pdf
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      assetID: $response.body#/assetID
      uploadUri: $response.body#/uploadUri
  - stepId: submitProperties
    description: >-
      Submit an asynchronous getPDFProperties job that inspects the uploaded
      PDF's metadata. Returns 201 with an in-progress job status.
    operationId: getPDFProperties
    parameters:
    - name: Authorization
      in: header
      value: "Bearer $inputs.accessToken"
    requestBody:
      contentType: application/json
      payload:
        assetID: $steps.requestUpload.outputs.assetID
        includePageLevelProperties: $inputs.includePageLevelProperties
    successCriteria:
    - condition: $statusCode == 201
    outputs:
      status: $response.body#/status
  - stepId: pollStatus
    description: >-
      Poll the getPDFProperties job until it reaches a terminal state. Loops
      back while the status is "in progress", branches to a success report when
      "done", and to a failure report when "failed".
    operationId: getJobStatus
    parameters:
    - name: Authorization
      in: header
      value: "Bearer $inputs.accessToken"
    - name: operationType
      in: path
      value: pdfproperties
    - name: jobID
      in: path
      value: $inputs.jobID
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      status: $response.body#/status
      outputAssetID: $response.body#/asset/assetID
      errorMessage: $response.body#/error/message
    onSuccess:
    - name: stillRunning
      type: goto
      stepId: pollStatus
      criteria:
      - context: $response.body
        condition: $.status == "in progress"
        type: jsonpath
    - name: succeeded
      type: goto
      stepId: reportSuccess
      criteria:
      - context: $response.body
        condition: $.status == "done"
        type: jsonpath
    - name: failed
      type: goto
      stepId: reportFailure
      criteria:
      - context: $response.body
        condition: $.status == "failed"
        type: jsonpath
  - stepId: reportSuccess
    description: >-
      Resolve a download URI for the properties output asset produced by a
      successful inspection job.
    operationId: getAsset
    parameters:
    - name: Authorization
      in: header
      value: "Bearer $inputs.accessToken"
    - name: assetID
      in: path
      value: $steps.pollStatus.outputs.outputAssetID
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      downloadUri: $response.body#/downloadUri
    onSuccess:
    - name: done
      type: end
  - stepId: reportFailure
    description: >-
      Re-read the job status to capture the error code and message when the
      inspection job failed, ending the workflow with the failure recorded.
    operationId: getJobStatus
    parameters:
    - name: Authorization
      in: header
      value: "Bearer $inputs.accessToken"
    - name: operationType
      in: path
      value: pdfproperties
    - name: jobID
      in: path
      value: $inputs.jobID
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      errorCode: $response.body#/error/code
      errorMessage: $response.body#/error/message
  outputs:
    sourceAssetID: $steps.requestUpload.outputs.assetID
    propertiesAssetID: $steps.pollStatus.outputs.outputAssetID
    downloadUri: $steps.reportSuccess.outputs.downloadUri
    failureMessage: $steps.reportFailure.outputs.errorMessage