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

# Request rating plans for product states

> Ask Effective to provide a rating plan for one or more of the product's configured states. Each state gets its own request, which Effective staff resolve as `available` or `unavailable`; poll listProductRatingPlanRequests for the outcome. Safe to retry: a state that already has an open or available request is returned unchanged with `created: false`, and the note is not updated. An unavailable state is requested again. Returns 201 when any request was created, otherwise 200. Requires a writable user credential.



## OpenAPI

````yaml /openapi.json post /insurance/products/{productId}/rating-plan-requests
openapi: 3.0.3
info:
  title: Effective API
  version: 2.0.0
  description: The public Effective REST API. Authenticate using an Effective API key.
servers:
  - url: https://api.canary.effectiveai.app/api/v2
    description: Canary
security:
  - bearerAuth: []
paths:
  /insurance/products/{productId}/rating-plan-requests:
    post:
      tags:
        - Products
      summary: Request rating plans for product states
      description: >-
        Ask Effective to provide a rating plan for one or more of the product's
        configured states. Each state gets its own request, which Effective
        staff resolve as `available` or `unavailable`; poll
        listProductRatingPlanRequests for the outcome. Safe to retry: a state
        that already has an open or available request is returned unchanged with
        `created: false`, and the note is not updated. An unavailable state is
        requested again. Returns 201 when any request was created, otherwise
        200. Requires a writable user credential.
      operationId: requestProductRatingPlans
      parameters:
        - schema:
            type: string
            description: >-
              Managed product_ ID or bare checked code; case-insensitive with
              Crockford aliases.
          required: true
          description: >-
            Managed product_ ID or bare checked code; case-insensitive with
            Crockford aliases.
          name: productId
          in: path
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/V2RatingPlanRequestCreate'
      responses:
        '200':
          description: Every state already had an open or available request.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2RatingPlanRequestCreated'
        '201':
          description: At least one request was created.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2RatingPlanRequestCreated'
        '400':
          description: >-
            invalid_id for a malformed product ID; invalid_request for invalid
            fields or states the product does not configure.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '401':
          description: Missing or invalid credentials, or credential scope denied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '403':
          description: The credential does not permit this operation.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '404':
          description: Product not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '415':
          description: Content-Type must be application/json.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '429':
          description: Rate limited. Honor Retry-After (seconds) when provided.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '500':
          description: Unexpected server error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
        '503':
          description: Dependency unavailable. Honor Retry-After (seconds).
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2CodedError'
      security:
        - bearerAuth: []
components:
  schemas:
    V2RatingPlanRequestCreate:
      type: object
      properties:
        states:
          type: array
          items:
            type: string
            minLength: 1
            maxLength: 200
          minItems: 1
          maxItems: 60
          description: >-
            States to request, from the product's configured availability.
            Case-insensitive; duplicates are ignored.
        note:
          type: string
          minLength: 1
          maxLength: 2000
          description: Context for Effective staff, up to 2,000 characters.
      required:
        - states
      additionalProperties: false
    V2RatingPlanRequestCreated:
      type: object
      properties:
        productId:
          type: string
          description: Canonical `product_` ID.
        requests:
          type: array
          items:
            $ref: '#/components/schemas/V2RatingPlanRequestResult'
      required:
        - productId
        - requests
      additionalProperties: false
    V2CodedError:
      allOf:
        - $ref: '#/components/schemas/V2Error'
        - type: object
          properties:
            code:
              type: string
              minLength: 1
              description: Stable error code. Clients must tolerate unknown future codes.
            details:
              type: array
              items:
                type: object
                properties:
                  location:
                    type: string
                    enum:
                      - path
                      - query
                      - header
                      - body
                  path:
                    type: array
                    items:
                      type: string
                      maxLength: 64
                    maxItems: 12
                  code:
                    type: string
                    enum:
                      - required
                      - invalid_type
                      - invalid_value
                      - unknown_field
                  message:
                    type: string
                    minLength: 1
                    maxLength: 200
                required:
                  - location
                  - path
                  - code
                  - message
              minItems: 1
              maxItems: 20
              description: Bounded safe validation issues; may omit some invalid fields.
            requestId:
              type: string
              minLength: 1
              maxLength: 128
              description: >-
                Existing server correlation for this HTTP attempt, when
                available.
            dataset:
              type: string
              enum:
                - naic
              description: Dataset needed for dataset_not_enabled.
          required:
            - code
    V2RatingPlanRequestResult:
      allOf:
        - $ref: '#/components/schemas/V2RatingPlanRequest'
        - type: object
          properties:
            created:
              type: boolean
              description: False when the state already had an open or available request.
          required:
            - created
          additionalProperties: false
    V2Error:
      type: object
      properties:
        error:
          type: string
          minLength: 1
          description: Human-readable explanation of the failure.
      required:
        - error
    V2RatingPlanRequest:
      type: object
      properties:
        id:
          type: string
          format: uuid
        productId:
          type: string
          description: Canonical `product_` ID.
        state:
          type: string
          description: The configured availability state, as listed on the product.
        status:
          type: string
          enum:
            - requested
            - available
            - unavailable
          description: >-
            `requested` until Effective staff resolve it; `available` when a
            rating plan exists for the state; `unavailable` when one cannot be
            provided (see `resolutionNote`).
        note:
          type: string
          nullable: true
          description: The requester's note, if any.
        resolutionNote:
          type: string
          nullable: true
          description: >-
            Why the plan is unavailable, or what an available plan covers. Null
            while open.
        raterId:
          type: string
          nullable: true
          description: The rater that serves an available plan, when one is named.
        createdAt:
          type: string
          format: date-time
        resolvedAt:
          type: string
          nullable: true
          format: date-time
      required:
        - id
        - productId
        - state
        - status
        - note
        - resolutionNote
        - raterId
        - createdAt
        - resolvedAt
      additionalProperties: false
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'Effective API key. Send Authorization: Bearer sk-eai-...'

````

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