Yandex Cloud
Search
Contact UsGet started
  • Blog
  • Pricing
  • Documentation
  • All Services
  • System Status
    • Featured
    • Infrastructure & Network
    • Data Platform
    • Containers
    • Developer tools
    • Serverless
    • Security
    • Monitoring & Resources
    • ML & AI
    • Business tools
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Customer Stories
    • Gateway to Russia
    • Cloud for Startups
    • Education and Science
  • Blog
  • Pricing
  • Documentation
Yandex project
© 2025 Yandex.Cloud LLC
Yandex Cloud Postbox
  • Getting started
  • Access management
  • Pricing policy
    • Authentication with the API
    • How to use the API
    • Signing requests
  • Audit Trails events
  • Release notes

In this article:

  • Amazon API use cases
  • Authentication with a static key
  • Authentication using an IAM token
  1. API reference
  2. Authentication with the API

Authentication with the Yandex Cloud Postbox API

Written by
Yandex Cloud
Updated at March 28, 2025
  • Amazon API use cases
    • Authentication with a static key
    • Authentication using an IAM token

You can access Yandex Cloud Postbox using the Amazon API. For authentication, use a static access key or an IAM token. This way, you will run all operations as the service account the static key or IAM token was issued to. For more information, see How to use the API.

To access the Amazon API directly, without the AWS CLI or apps, use one of these methods:

  • Manually generate a request signature and provide it in the Authorization header. To learn more about signing requests and verifying signatures, see Signing requests.
  • Authenticate with an IAM token you get for the service account and provide it in the X-YaCloud-SubjectToken header. In this case, you do not need the Authorization header and signature.

Amazon API use casesAmazon API use cases

The examples below show how to get a list of configurations with a request sent via cURL.

Before you start, create a service account with the appropriate role. The postbox.viewer role works well for these examples.

Authentication with a static keyAuthentication with a static key

  1. Create a static key for the service account.

  2. Run this request:

    export AWS_KEY_ID="<static_key_ID>" && \
    export AWS_SECRET_KEY="<secret_key>" && \
    curl \
       --request GET \
       --user "${AWS_KEY_ID}:${AWS_SECRET_KEY}" \
       --aws-sigv4 "aws:amz:ru-central1:ses" \
       --url 'https://postbox.cloud.yandex.net/v2/email/configuration-sets' \
       --verbose
    

Authentication using an IAM tokenAuthentication using an IAM token

  1. Get an IAM token for the service account.

  2. Run this request:

    export IAM_TOKEN="<IAM_token>" && \
    curl \
       --request GET \
       --header "X-YaCloud-SubjectToken: ${IAM_TOKEN}" \
       --url 'https://postbox.cloud.yandex.net/v2/email/configuration-sets' \
       --verbose
    

Was the article helpful?

Previous
Pricing policy
Next
How to use the API
Yandex project
© 2025 Yandex.Cloud LLC