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

# Get the active sending-profile mapping for an object/record-type

> Org-facing mapping fetch for the managed package's send LWC: match key, prefill fields, writeback fields, and the resolved send-field catalog for the firm's active, activated, interactive-send-enabled v2 sending profile matching the given object and record type. Requires FULL tier.



## OpenAPI

````yaml /api-reference/openapi.yml get /salesforce/send-mapping
openapi: 3.0.3
info:
  title: CaseXchange Public API
  version: 1.0.0
  description: >-
    The CaseXchange Public API enables law firms to integrate referral
    management

    directly into their own systems.


    ## Authentication

    All requests must include an `X-API-Key` header containing a valid API key

    (format: `cxp_<hex>`). Keys are scoped to a firm and an access tier.


    ## Access Tiers

    | Tier | Description |

    |------|-------------|

    | `read_only` | GET endpoints — read data without mutation |

    | `standard` | read_only + create/update case referrals |

    | `full` | standard + delete, routing rules, bulk import, firm mutation |


    ## Rate Limiting

    Rate limits are enforced per API key. Exceeded limits return `429 Too Many
    Requests`.


    ## Pagination

    List endpoints accept `page` (default 1) and `limit` (default 20, max 100)
    query params.


    ## Response Format

    Successful responses are wrapped in `{ data: T, meta: { requestId, timestamp
    } }`.

    Errors are wrapped in `{ error: { code, message }, meta: { requestId,
    timestamp } }`.
  contact:
    name: CaseXchange API Support
    url: https://casexchange.com
servers:
  - url: https://api.casexchange.com/api/public/v1
    description: Production Public API base path
  - url: /api/public/v1
    description: Relative base path (for proxied docs/local environments)
security: []
tags:
  - name: Reference Data
    description: Case types, jurisdictions, and counties
  - name: Firms
    description: Firm directory and profile management
  - name: Cases
    description: Case referral lifecycle and actions
  - name: Sent Cases
    description: 'Sender-side case management: create, track, and refer/route cases you own'
  - name: Documents
    description: Document upload, download, and management
  - name: Users
    description: User management within the caller's firm
  - name: Routing
    description: Referral routing rules
  - name: Analytics
    description: Dashboard and case analytics
  - name: Notifications
    description: Notification preferences and email management
  - name: Med Cases
    description: Med Xchange cases and their nested referrals to medical providers
  - name: MedEx Documents
    description: Med Xchange case document listing and download
  - name: Import
    description: Bulk case import/update via CSV
  - name: Salesforce
    description: Org-facing endpoints consumed by the CaseXchange managed package
paths:
  /salesforce/send-mapping:
    get:
      tags:
        - Salesforce
      summary: Get the active sending-profile mapping for an object/record-type
      description: >-
        Org-facing mapping fetch for the managed package's send LWC: match key,
        prefill fields, writeback fields, and the resolved send-field catalog
        for the firm's active, activated, interactive-send-enabled v2 sending
        profile matching the given object and record type. Requires FULL tier.
      operationId: getSalesforceSendMapping
      parameters:
        - name: sfObjectApiName
          in: query
          required: true
          schema:
            type: string
          description: Salesforce object API name, e.g. litify_pm__Matter__c
        - name: sfRecordTypeDevName
          in: query
          schema:
            type: string
          description: >-
            Optional record type developer name. Omit to match profiles with no
            record type set.
      responses:
        '200':
          description: Send mapping for the given object/record type
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/SendMapping'
                  meta:
                    type: object
                    properties:
                      requestId:
                        type: string
                        example: req_f2dbe1d3f6ad4a7bb5b4c9f2
                      timestamp:
                        type: string
                        format: date-time
                    required:
                      - requestId
                      - timestamp
                required:
                  - data
                  - meta
        '400':
          description: Request validation failed
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                  meta:
                    type: object
                    properties:
                      requestId:
                        type: string
                        example: req_f2dbe1d3f6ad4a7bb5b4c9f2
                      timestamp:
                        type: string
                        format: date-time
                    required:
                      - requestId
                      - timestamp
                required:
                  - error
                  - meta
        '401':
          description: Invalid or missing API key
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                  meta:
                    type: object
                    properties:
                      requestId:
                        type: string
                        example: req_f2dbe1d3f6ad4a7bb5b4c9f2
                      timestamp:
                        type: string
                        format: date-time
                    required:
                      - requestId
                      - timestamp
                required:
                  - error
                  - meta
        '403':
          description: API key tier does not permit this action
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                  meta:
                    type: object
                    properties:
                      requestId:
                        type: string
                        example: req_f2dbe1d3f6ad4a7bb5b4c9f2
                      timestamp:
                        type: string
                        format: date-time
                    required:
                      - requestId
                      - timestamp
                required:
                  - error
                  - meta
        '404':
          description: Resource not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                  meta:
                    type: object
                    properties:
                      requestId:
                        type: string
                        example: req_f2dbe1d3f6ad4a7bb5b4c9f2
                      timestamp:
                        type: string
                        format: date-time
                    required:
                      - requestId
                      - timestamp
                required:
                  - error
                  - meta
      security:
        - apiKeyAuth: []
components:
  schemas:
    SendMapping:
      type: object
      description: >-
        The active v2 sending profile's mapping for one (sfObjectApiName,
        sfRecordTypeDevName) pair, consumed by the managed package's send LWC
        (spec §6).
      properties:
        profile:
          type: object
          properties:
            id:
              type: string
              format: uuid
            sfObjectApiName:
              type: string
            sfRecordTypeDevName:
              type: string
              nullable: true
            version:
              type: string
              format: date-time
              description: >-
                Observability marker only — the send endpoint re-reads current
                config server-side.
          required:
            - id
            - sfObjectApiName
            - sfRecordTypeDevName
            - version
        matchKey:
          type: object
          nullable: true
          description: >-
            Discriminated union: {mode:'externalId', fieldName} or
            {mode:'lookup', lookupField, relatedExternalIdField}.
          properties:
            mode:
              type: string
              enum:
                - externalId
                - lookup
            fieldName:
              type: string
            lookupField:
              type: string
            relatedExternalIdField:
              type: string
        prefill:
          type: array
          items:
            type: object
            properties:
              canonicalKey:
                type: string
                example: matter.status
              sfFieldApiName:
                type: string
                example: litify_pm__Matter_Status__c
            required:
              - canonicalKey
              - sfFieldApiName
          description: >-
            Fields to prefill on the send form from CaseXchange (toCx /
            bidirectional links).
        writeback:
          type: array
          items:
            type: object
            properties:
              canonicalKey:
                type: string
                example: matter.status
              sfFieldApiName:
                type: string
                example: litify_pm__Matter_Status__c
            required:
              - canonicalKey
              - sfFieldApiName
          description: >-
            Fields the org expects written back after send (toSf / bidirectional
            links).
        sendFields:
          type: array
          items:
            type: object
            properties:
              canonicalKey:
                type: string
              payloadKey:
                type: string
              label:
                type: string
              type:
                type: string
              required:
                type: boolean
              editable:
                type: boolean
              prefillSfFieldApiName:
                type: string
                nullable: true
            required:
              - canonicalKey
              - payloadKey
              - label
              - type
              - required
              - editable
              - prefillSfFieldApiName
          description: >-
            The full send-field catalog with prefill values resolved where
            available.
      required:
        - profile
        - matchKey
        - prefill
        - writeback
        - sendFields
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
      description: Public API key (starts with cxp_). Required on every request.

````