> ## Documentation Index
> Fetch the complete documentation index at: https://api.docs.flare.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Identifier Alert

> Create an alert on an identifier and return it. Only the `email` and `channel` alert types are accepted. `frequency` is the interval between notifications in seconds, `start_at` is the date the alert starts and `params` holds the settings of the chosen type. `search_types`, `experimental_search_types` and `risks` are stored as the event filters of the alert. Requires write access to the tenant's alerts.

&#x20;Required API key permission: **Write Tenant**


## OpenAPI

````yaml firework-v2-openapi post /firework/v2/assets/{asset_id}/alerts
openapi: 3.0.1
info:
  description: >

    Manage and access Firework resources.


    Requests are authenticated with API tokens, which are obtained using an API
    key:


    1. Generate an API key from the [Profile
    page](https://app.flare.io/#/profile).

    2. Send a `POST` request to `https://api.flare.io/tokens/generate` with the
    `Authorization: <api-key>` header to get an API token. API tokens expire
    after 1 hour.

    3. Call the API endpoints with the `Authorization: Bearer <api-token>`
    header.


    See [Authentication](https://api.docs.flare.io/concepts/authentication) for
    details.
  title: Firework API
  version: v2
servers:
  - url: https://api.flare.io/
security:
  - BearerAuth: []
tags:
  - description: >-
      The authenticated user, its API keys, organizations, tenants, onboarding
      and usage.
    name: Account
  - description: >-
      Events collected by Flare: global search, tenant and identifier feeds,
      event details, actions and saved feed views.
    name: Events
  - description: >-
      Identifiers are the assets a tenant monitors, such as domains, keywords
      and email addresses. Includes recommendations and authorization of
      sensitive identifiers.
    name: Identifiers
  - description: Report groups, reports, their sections, schedules and delivery channels.
    name: Reports
paths:
  /firework/v2/assets/{asset_id}/alerts:
    post:
      tags:
        - Identifiers
      summary: Create an identifier alert
      description: >-
        Create an alert on an identifier and return it. Only the `email` and
        `channel` alert types are accepted. `frequency` is the interval between
        notifications in seconds, `start_at` is the date the alert starts and
        `params` holds the settings of the chosen type. `search_types`,
        `experimental_search_types` and `risks` are stored as the event filters
        of the alert. Requires write access to the tenant's alerts.
      operationId: post_asset_alerts
      parameters:
        - description: ID of the identifier.
          in: path
          name: asset_id
          required: true
          schema:
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/FeedAlert'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FeedAlert'
          description: Success
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HttpError'
          description: >-
            Invalid body: `INVALID_FREQUENCY`, `INVALID_START_AT`,
            `INVALID_CREATED_AT`, `INVALID_ALERT_TYPE` (type other than `email`
            or `channel`), `INVALID_ALERT_PARAMS`, `INVALID_SEVERITIES` (unknown
            risk score) or `INVALID_SEARCH_TYPES` (search types the organization
            cannot use), or `INVALID_PARAMS` when the alert cannot be created.
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HttpError'
          description: The caller lacks the required permission (`FORBIDDEN`).
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HttpError'
          description: The identifier does not exist.
components:
  schemas:
    FeedAlert:
      properties:
        name:
          type: string
        id:
          type: integer
        type:
          enum:
            - email
            - channel
            - azure_sentinel
            - azure_sentinel_v2
            - slack
            - discord
            - splunk
            - jira
            - teams
            - servicenow
            - webhook
          example: email
          type: string
        feed_url:
          type: string
        feed_target_type:
          enum:
            - assets/groups
            - assets
            - home
          example: assets/groups
          type: string
        feed_target_id:
          type: integer
        frequency:
          type: integer
        start_at:
          format: date-time
          type: string
        created_at:
          format: date-time
          type: string
        params:
          properties: {}
          type: object
        tenant_id:
          type: integer
        organization_id:
          type: integer
        search_types:
          items:
            enum:
              - attachment
              - listing
              - ransomleak
              - forum_post
              - forum_topic
              - forum_profile
              - blog_post
              - seller
              - paste
              - leak
              - chat_message
              - domain
              - bot
              - stealer_log
              - infected_devices
              - driller
              - driller_forum_topic
              - driller_forum_post
              - driller_profile
              - cc
              - ccbin
              - financial_data
              - leaked_data
              - leaked_file
              - document
              - account
              - actor
              - forum_content
              - blog_content
              - profile
              - leaked_credential
              - valid_credential
              - invalid_credential
              - mitigated_credential
              - illicit_networks
              - open_web
              - domains
              - intelligence_object
              - leaks
              - social_media_account
              - social_media
              - source_code
              - source_code_secrets_np
              - source_code_secrets
              - source_code_files
              - secret
              - docker
              - stack_exchange
              - google
              - service
              - driller_host
              - buckets
              - bucket
              - bucket_object
              - whois
              - ad
              - ads
              - cookie
              - pii
              - experimental
              - lookalike_discovery
              - lookalike_title
              - lookalike_favicon
              - lookalike_screenshot
              - lookalike_ip_address
              - lookalike_dns
              - lookalike_whois_rdap
              - lookalike_ssl_certificate
            example: attachment
            type: string
          type: array
        experimental_search_types:
          items:
            type: string
          type: array
        risks:
          items:
            type: integer
          type: array
        tenant_alert_channel_id:
          type: integer
      required:
        - frequency
        - params
        - start_at
        - type
      type: object
    HttpError:
      properties:
        message:
          description: Human-readable description of the error.
          type: string
        code:
          description: Machine-readable error code.
          type: string
      type: object
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.