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

# Create Platform

> Create a new marketing platform record for the caller's (or tenant's) first visible location.



## OpenAPI

````yaml post /opportunity/platform
openapi: 3.1.0
info:
  title: Decoda API
  description: External API documentation for the Decoda Health platform.
  version: '1.0'
servers: []
security: []
paths:
  /opportunity/platform:
    post:
      tags:
        - Marketing Platforms
      summary: Create Platform
      description: >-
        Create a new marketing platform record for the caller's (or tenant's)
        first visible location.
      operationId: create_platform_opportunity_platform_post
      parameters:
        - name: TENANT
          in: header
          required: true
          schema:
            type: string
            title: Tenant
          description: The tenant you are making this request on behalf of
        - name: API-KEY
          in: header
          required: true
          schema:
            type: string
            title: Api-Key
          description: Your api key
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PlatformCreate'
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PlatformSummary'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    PlatformCreate:
      properties:
        name:
          type: string
          minLength: 1
          title: Name
        url:
          anyOf:
            - type: string
            - type: 'null'
          title: Url
        icon:
          anyOf:
            - type: string
            - type: 'null'
          title: Icon
      type: object
      required:
        - name
      title: PlatformCreate
    PlatformSummary:
      properties:
        id:
          type: string
          title: Id
        name:
          type: string
          title: Name
        locationId:
          type: string
          title: Locationid
        url:
          anyOf:
            - type: string
            - type: 'null'
          title: Url
        icon:
          anyOf:
            - type: string
            - type: 'null'
          title: Icon
        isActive:
          type: boolean
          title: Isactive
          default: true
        platformType:
          $ref: '#/components/schemas/PlatformType'
          default: CUSTOM
        isConnected:
          type: boolean
          title: Isconnected
          default: false
        createdDate:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Createddate
        updatedDate:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Updateddate
      type: object
      required:
        - id
        - name
        - locationId
      title: PlatformSummary
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    PlatformType:
      type: string
      enum:
        - GOOGLE_ADS
        - META_ADS
        - WEB_FORM
        - CUSTOM
      title: PlatformType
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````