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

# Add a geographic area to a market

> Areas compose a market. Supply the `type` field and the matching fields: postalCodes (postal), admin* fields (admin), geometry (polygon), h3Cells (h3), or sourceRef (serviceability — must name an active serviceability integration source owned by your team). Use operation=exclude to carve a hole out of the market.



## OpenAPI

````yaml /openapi/openapi-provider.json post /provider/markets/{id}/areas
openapi: 3.0.0
info:
  title: OfferGrid API
  description: >-
    **Provider API** - Create and manage service offerings, fulfill orders from
    resellers.


    As a provider, you can:

    - Create and publish service offerings (internet, electricity)

    - Control which resellers can access your offers (all, preferred, or
    selected)

    - View and manage orders from resellers

    - Update order fulfillment status and schedule installations

    - Track order lifecycle from pending to completion
  version: '1.0'
  contact: {}
servers:
  - url: https://api.offergrid.io
    description: Production
  - url: http://localhost:3000
    description: Local development
security: []
tags:
  - name: provider-offers
    description: 'Provider: Manage your service offerings'
  - name: provider-orders
    description: 'Provider: Fulfill orders from resellers'
paths:
  /provider/markets/{id}/areas:
    post:
      tags:
        - provider-markets
      summary: Add a geographic area to a market
      description: >-
        Areas compose a market. Supply the `type` field and the matching fields:
        postalCodes (postal), admin* fields (admin), geometry (polygon), h3Cells
        (h3), or sourceRef (serviceability — must name an active serviceability
        integration source owned by your team). Use operation=exclude to carve a
        hole out of the market.
      operationId: ProviderMarketsController_addArea
      parameters:
        - name: id
          required: true
          in: path
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpsertMarketAreaDto'
      responses:
        '201':
          description: ''
      security:
        - api-key: []
components:
  schemas:
    UpsertMarketAreaDto:
      type: object
      properties:
        type:
          type: string
          enum:
            - postal
            - admin
            - polygon
            - h3
            - utility_territory
            - serviceability
        operation:
          type: string
          enum:
            - include
            - exclude
          default: include
        label:
          type: string
          description: Optional display label (e.g. "Travis County", "78704 cluster").
        postalCodes:
          example:
            - '78701'
            - '78702'
          type: array
          items:
            type: string
        postalCountry:
          type: string
          example: US
        adminLevel:
          type: string
          enum:
            - state
            - county
            - city
            - census_place
        adminCountry:
          type: string
          example: US
        adminState:
          type: string
          example: TX
        adminCounty:
          type: string
          example: Travis
        adminCity:
          type: string
          example: Austin
        adminGeoid:
          type: string
          description: Census GEOID for stable matching.
        geometry:
          type: object
          description: GeoJSON Polygon or MultiPolygon.
        h3Cells:
          type: array
          items:
            type: string
        h3Resolution:
          type: number
          example: 8
        utilityCodes:
          description: TDSP/TDU DUNS codes, e.g. Oncor "1039940674000".
          example:
            - '1039940674000'
          type: array
          items:
            type: string
        utilityCountry:
          type: string
          example: US
        sourceType:
          type: string
          enum:
            - fabric_upload
            - external_api
        sourceRef:
          type: string
          description: >-
            The IntegrationSource key this area resolves through. Required for
            serviceability areas, where it must name an active serviceability
            source owned by your team.
        gating:
          type: boolean
          description: >-
            Serviceability areas only. true = the market covers an address only
            when this source answers on-net; false (default) = the source
            enriches offer detail but never hides the offer. An unanswerable
            lookup never gates.
          default: false
      required:
        - type
      title: Upsert Market Area
  securitySchemes:
    api-key:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        Team API key for authentication. Your team role
        (provider/reseller/hybrid) determines which endpoints you can access.

````