OpenAPI-Based APIs openapi-based-apis

NOTE
OpenAPIs are available as part of an early access program. If you are interested in accessing them, we encourage you to email aem-apis@adobe.com with a description of your use case.

Newer AEM as a Cloud Service APIs follow the OpenAPI specification, and thus produce consistent, well-documented, and user-friendly APIs. In-depth information is available in the following pages:

A common API use case involves integrations with systems such as a CRM or PIM, where AEM APIs are invoked to retrieve or persist data. As part of the integration implementation, applications may subscribe to AEM-emitted events, which can trigger business logic in Adobe App Builder or other infrastructure.

Supported API authentication types differ based on the endpoint, but may be OAuth Server-to-Server, OAuth Web App, and OAuth Single Page App (SPA).

NOTE
The end-to-end tutorial is a recommended resource to learn how to configure and invoke the OpenAPI-based AEM APIs.

Configuring API Access configuring-api-access

Many OpenAPI-based AEM APIs require authentication, which requires credentials to be generated using Adobe Developer Console. Configuration involves the following steps, which are illustrated in the tutorial:

  1. Ensure your AEM program’s product profiles are updated and have an appropriate service enabled to access the desired API.
  2. Create a new project in Adobe Developer Console and add the desired API(s) to the project, also selecting the appropriate authentication type.
  3. Generate the credential, which will later be used to exchange fora bearer token when invoking the API.
  4. Register the client ID with the environment by configuring a YAML file, which is deployed using the Config Pipeline (or commandline for RDEs).

Registering a Client ID registering-a-client-id

Client IDs scope the APis in an Adobe Developer Console project to specific AEM environments. This is achieved as follows:

  1. Create a file named api.yaml or similar with a configuration like the snippet below, including the desired tiers (author, publish, preview). Client_id values should come from your Adobe Developer Console API project(s).

    The kind, version, and metadata properties are described in the Config Pipeline article. The kind property value should be set to API and the version property should be set to 1.

    code language-none
    kind: "API"
    version: "1"
    metadata:
      envTypes: ["dev"]
    data:
      allowedClientIDs:
        author:
          - "<client_id>"
        publish:
          - "<client_id>"
        preview:
          - "<client_id>"
    
  2. Place the file somewhere under a top level folder named config or similar, as described under Config Pipeline.

  3. For environment types other than RDE (which uses command line tooling), create a targeted deployment config pipeline in Cloud Manager, as referenced by this section in the Config Pipeline article. Note that Full Stack pipelines and Web Tier pipelines do not deploy the configuration file.

  4. Deploy the configuration.

recommendation-more-help
fbcff2a9-b6fe-4574-b04a-21e75df764ab