---
title: "Create an email access policy"
method: POST
path: "/api/v2/statuspages/{page_id}/access_policies/email"
tags: ["Status Pages"]
---

# Create an email access policy

`POST /api/v2/statuspages/{page_id}/access_policies/email`

## Request

- Base URL: `https://api.datadoghq.com`
- URL: `https://api.datadoghq.com/api/v2/statuspages/{page_id}/access_policies/email`
- Auth: one of:
  - API key in header `DD-API-KEY` and API key in header `DD-APPLICATION-KEY`
  - OAuth 2
    - Authorization code: `/oauth2/v1/authorize`
    - Token URL: `/oauth2/v1/token` scopes: `status_pages_settings_write`

Creates an email access policy for a private status page.

## Path parameters

- `page_id` string, uuid, required

## Query parameters

- `include` string

## Request body

- CreateStatusPageEmailAccessPolicyRequest: Request object for creating a status page email access policy.
  - `data` CreateStatusPageEmailAccessPolicyRequestData, required: The data object for creating a status page email access policy.
    - `attributes` CreateStatusPageEmailAccessPolicyRequestDataAttributes, required: Attributes for creating a status page email access policy.
      - `effect` 'allow' | 'deny', required: The effect applied when an email address matches the policy. Deny policies take precedence over allow policies.
      - `pattern` string, required: The email address pattern matched by the policy. Supports an exact address (`user@example.com`), all addresses in a domain (`@example.com`), or all addresses in subdomains (`@*.example.com`).
    - `type` 'email_access_policies', required: Status page email access policy resource type.

## Response `201`

Created

- StatusPageEmailAccessPolicyResponse: Response object for a status page email access policy.
  - `data` StatusPageEmailAccessPolicyData, required: The data object for a status page email access policy.
    - `attributes` StatusPageEmailAccessPolicyDataAttributes, required: Attributes of a status page email access policy.
      - `created_at` string, date-time, required: Timestamp of when the email access policy was created.
      - `effect` 'allow' | 'deny', required: The effect applied when an email address matches the policy. Deny policies take precedence over allow policies.
      - `pattern` string, required: The email address pattern matched by the policy.
    - `id` string, uuid, required: The ID of the email access policy.
    - `relationships` StatusPageEmailAccessPolicyDataRelationships, required: Relationships of a status page email access policy.
      - `created_by_user` StatusPageEmailAccessPolicyDataRelationshipsCreatedByUser, required: The Datadog user who created the email access policy.
        - `data` StatusPageEmailAccessPolicyDataRelationshipsCreatedByUserData, required: The data object identifying the Datadog user who created the email access policy.
          - `id` string, uuid, required: The ID of the Datadog user who created the email access policy.
          - `type` 'users', required: Users resource type.
      - `status_page` StatusPageEmailAccessPolicyDataRelationshipsStatusPage, required: The status page associated with the email access policy.
        - `data` StatusPageEmailAccessPolicyDataRelationshipsStatusPageData, required: The data object identifying the status page associated with the email access policy.
          - `id` string, uuid, required: The ID of the status page associated with the email access policy.
          - `type` 'status_pages', required: Status pages resource type.
    - `type` 'email_access_policies', required: Status page email access policy resource type.
  - `included` StatusPageEmailAccessPolicyIncluded[]: Resources related to the email access policy, when requested using the `include` query parameter.
    - union: An included resource related to a status page email access policy.
      - StatusPagesUser: The included Datadog user resource.
        - `attributes` StatusPagesUserAttributes: Attributes of the Datadog user.
          - `email` string: The email of the Datadog user.
          - `handle` string: The handle of the Datadog user.
          - `icon` string: The icon of the Datadog user.
          - `name` string: The name of the Datadog user.
          - `uuid` string: The UUID of the Datadog user.
        - `id` string, uuid: The ID of the Datadog user.
        - `type` 'users', required: Users resource type.
      - StatusPageAsIncluded: The included status page resource.
        - `attributes` StatusPageAsIncludedAttributes: The attributes of a status page.
          - `company_logo` string: The base64-encoded image data displayed in the company logo.
          - `components` StatusPageAsIncludedAttributesComponentsItems[]: Components displayed on the status page.
            - `components` StatusPageAsIncludedAttributesComponentsItemsComponentsItems[]: If the component is of type `group`, the components within the group.
              - …
            - `id` string, uuid: The ID of the component.
            - `name` string: The name of the component.
            - `position` integer: The zero-indexed position of the component.
            - `status` 'operational' | 'degraded' | 'partial_outage' | 'major_outage' | 'maintenance': The status of the component.
            - `type` 'component' | 'group': The type of the component.
          - `created_at` string, date-time: Timestamp of when the status page was created.
          - `custom_domain` string: If configured, the url that the status page is accessible at.
          - `custom_domain_enabled` boolean: Whether the custom domain is configured.
          - `domain_prefix` string: The subdomain of the status page URL. Public pages use `https://{domain_prefix}.statuspage.datadoghq.com`, while private pages use `https://{domain_prefix}.private.statuspage.datadoghq.com`. Globally unique across Datadog Status Pages.
          - `email_header_image` string: Base64-encoded image data included in email notifications sent to status page subscribers.
          - `email_notifications_enabled` boolean: Whether email notifications are enabled for the status page. Must be enabled when `subscriptions_enabled` is `true`.
          - `enabled` boolean: Whether the status page is enabled.
          - `favicon` string: Base64-encoded image data displayed in the browser tab.
          - `modified_at` string, date-time: Timestamp of when the status page was last modified.
          - `ms_teams_subscriptions_enabled` boolean: Whether Microsoft Teams subscriptions are enabled for the status page.
          - `name` string: The name of the status page.
          - `page_url` string: The url that the status page is accessible at.
          - `rss_feed_enabled` boolean: Whether the RSS feed is enabled for the status page.
          - `slack_app_icon` string: The Slack app icon URL for the status page.
          - `slack_subscriptions_enabled` boolean: Whether Slack subscriptions are enabled for the status page.
          - `subscriptions_enabled` boolean: Whether users can subscribe to the status page.
          - `type` 'public' | 'internal' | 'private': The type of the status page controlling how the status page is accessed. Public pages are accessible to anyone, internal pages are accessible to authenticated users in the Datadog organization, and private pages are accessible only to users matching an allow email access policy and no deny email access policy.
          - `visualization_layout` 'list' | 'grid': The layout of components on the status page. Defaults to `list`. `grid` requires `visualization_type` to be `component_name_only`; changing `visualization_type` to any other value resets the layout to `list`.
          - `visualization_type` 'bars_and_uptime_percentage' | 'bars_only' | 'component_name_only': The visualization type of the status page.
        - `id` string, uuid: The ID of the status page.
        - `relationships` StatusPageAsIncludedRelationships: The relationships of a status page.
          - `created_by_user` StatusPageAsIncludedRelationshipsCreatedByUser: The Datadog user who created the status page.
            - `data` StatusPageAsIncludedRelationshipsCreatedByUserData, required: The data object identifying the Datadog user who created the status page.
              - …
          - `last_modified_by_user` StatusPageAsIncludedRelationshipsLastModifiedByUser: The Datadog user who last modified the status page.
            - `data` StatusPageAsIncludedRelationshipsLastModifiedByUserData, required: The data object identifying the Datadog user who last modified the status page.
              - …
        - `type` 'status_pages', required: Status pages resource type.

## Other responses

- `400`: Bad Request
- `403`: Forbidden
- `404`: Not Found
- `409`: Conflict
- `429`: Too many requests

## Changes

- **2026-11-12** `6cc2bb1f7a80`: 4 info
  - added the optional property `errors/items/code` to the response with the `400` status
  - added the optional property `errors/items/code` to the response with the `403` status
  - added the optional property `errors/items/code` to the response with the `404` status
  - added the optional property `errors/items/code` to the response with the `409` status
- **2026-11-09** `083fac905f89`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/datadog/apis/datadog-api-v2-collection/changes/api/v2/statuspages/:page_id/access_policies/email/post.md)

---

[API](https://skmtc.dev/datadog/apis/datadog-api-v2-collection.md) - [All operations](https://skmtc.dev/datadog/apis/datadog-api-v2-collection/llms.txt) - [OpenAPI document](https://skmtc.dev/datadog/apis/datadog-api-v2-collection/revisions/14d85160bfa9?raw)
