UserGems Accounts API

Add and remove accounts UserGems should source prospects against.

OpenAPI Specification

usergems-accounts-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: UserGems Accounts API
  description: 'The UserGems API lets customers programmatically add contacts to track for job

    changes and add accounts to receive prospects for. It also exposes a privacy

    delete endpoint used to honor data-subject removal requests. Requests are

    authenticated with a customer-issued API key sent in the X-Api-Key header and

    are processed asynchronously — responses confirm enqueueing, not completion.

    '
  version: 1.0.0
  contact:
    name: UserGems
    url: https://www.usergems.com
    email: support@usergems.com
  license:
    name: UserGems Terms of Service
    url: https://www.usergems.com/legal/terms
servers:
- url: https://api.usergems.com/v1
  description: Production
security:
- ApiKeyAuth: []
tags:
- name: Accounts
  description: Add and remove accounts UserGems should source prospects against.
paths:
  /account:
    post:
      summary: Add Account
      description: 'Enqueue an account so UserGems sources prospects against it. Accounts are

        identified by the (name, domain) pair; optional fields associate the

        account with a Salesforce ID, a custom ID, a report name, and a signal

        label so prospects can be routed back to the right workflow.

        '
      operationId: addAccount
      tags:
      - Accounts
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AddAccountRequest'
            examples:
              AddAccountExample:
                $ref: '#/components/examples/AddAccountExample'
      responses:
        '200':
          description: Account added.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/QueueAck'
              examples:
                AddAccountAck:
                  $ref: '#/components/examples/AddAccountAck'
        4XX:
          $ref: '#/components/responses/ErrorResponse'
        5XX:
          $ref: '#/components/responses/ErrorResponse'
    delete:
      summary: Delete Account
      description: 'Remove a previously added account. Identified by (name, domain); the

        optional reportName, signal, salesforceId, and customId fields scope the

        deletion to a specific routing context.

        '
      operationId: deleteAccount
      tags:
      - Accounts
      parameters:
      - name: name
        in: query
        required: true
        description: Account name as previously submitted.
        schema:
          type: string
      - name: domain
        in: query
        required: true
        description: Primary domain for the account.
        schema:
          type: string
      - name: reportName
        in: query
        required: false
        description: Report or workflow grouping the account belongs to.
        schema:
          type: string
      - name: signal
        in: query
        required: false
        description: Signal label originally attached to the account.
        schema:
          type: string
      - name: salesforceId
        in: query
        required: false
        description: Salesforce Account ID for cross-reference.
        schema:
          type: string
      - name: customId
        in: query
        required: false
        description: Customer-supplied identifier for cross-reference.
        schema:
          type: string
      responses:
        '200':
          description: Account deleted.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/QueueAck'
              examples:
                DeleteAccountAck:
                  $ref: '#/components/examples/DeleteAccountAck'
        4XX:
          $ref: '#/components/responses/ErrorResponse'
        5XX:
          $ref: '#/components/responses/ErrorResponse'
components:
  responses:
    ErrorResponse:
      description: Error response. UserGems returns standard HTTP status codes (400, 401, 403, 404, 405, 406, 410, 429, 500, 503).
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  examples:
    AddAccountAck:
      summary: Account accepted
      value:
        message: Account added
    DeleteAccountAck:
      summary: Account removed
      value:
        message: Account deleted
    AddAccountExample:
      summary: Add a target account
      value:
        name: Acme Inc
        domain: acme.com
        reportName: Q2-Enterprise-ICP
        signal: hiring-vp-sales
        salesforceId: 0014x00000ABCDeAAA
  schemas:
    AddAccountRequest:
      type: object
      required:
      - name
      - domain
      properties:
        name:
          type: string
          description: Account name (display name of the target company).
        domain:
          type: string
          description: Primary domain for the target company (e.g. example.com).
        reportName:
          type: string
          description: Report or workflow grouping the account belongs to.
        signal:
          type: string
          description: Signal label to associate with prospects routed for this account.
        salesforceId:
          type: string
          description: Salesforce Account ID for cross-reference.
        customId:
          type: string
          description: Customer-supplied identifier for cross-reference.
        custom:
          type: string
          description: Free-form custom metadata to round-trip with downstream events.
    QueueAck:
      type: object
      required:
      - message
      properties:
        message:
          type: string
          description: Human-readable confirmation message.
    Error:
      type: object
      required:
      - message
      properties:
        message:
          type: string
          description: Human-readable error message.
        code:
          type: string
          description: Optional machine-readable error code.
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-Api-Key
      description: 'Customer-issued API key. Request a key from support@usergems.com. The

        key must be included on every request in the X-Api-Key header.

        '