Joblogic Customers API

Customer account records.

OpenAPI Specification

joblogic-customers-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: Joblogic Assets Customers API
  description: 'The Joblogic API is the REST interface to the Joblogic cloud field service management (FSM) platform, covering customers, contacts, sites, assets, jobs, engineer visits, engineers, quotes, and invoices for trades, service, and maintenance contractors. All resource paths sit under `/api/v1`.


    Access model: Joblogic API access is customer-provisioned and gated. A caller is issued a Client ID, Client Secret, and Tenant ID by Joblogic, and the caller''s public IP addresses are allowlisted behind Joblogic''s firewall before requests are accepted. Integrations are first developed against a per-customer UAT sandbox (web app at https://uat.joblogic.com, API host https://uatapi.joblogic.com) and then promoted to production.


    Authentication: Each request must carry a Bearer access token obtained from the Joblogic IdentityServer token endpoint using the OAuth2 client-credentials grant (client_id, client_secret, grant_type, scope). Access tokens expire after one hour; expired or missing tokens return 401 Unauthorized.


    Multi-tenancy: Most operations require a `tenantId` (the caller''s Joblogic tenant, a GUID) supplied as a query parameter.


    Modeling note: This document is modeled by API Evangelist from Joblogic''s published Postman documentation at https://apidocs.joblogic.com/. Endpoint paths, methods, and the auth flow are confirmed from that collection. Request and response schemas are representative - the live API is IP-allowlisted, so payload bodies could not be exercised directly and are illustrative rather than exhaustive.'
  version: v1
  contact:
    name: Joblogic Support
    url: https://support.joblogic.com/docs/api-access
    email: support@joblogic.com
servers:
- url: https://api.joblogic.com/api/v1
  description: Production API host (live; firewall / IP-allowlisted, customer-provisioned). The exact production host is confirmed to callers during onboarding.
- url: https://uatapi.joblogic.com/api/v1
  description: UAT sandbox API host used for integration development.
security:
- oauth2ClientCredentials: []
tags:
- name: Customers
  description: Customer account records.
paths:
  /Customer/GetAll:
    post:
      operationId: searchCustomers
      tags:
      - Customers
      summary: Search customers
      description: Searches customers by keyword, tags, and active status.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SearchRequest'
      responses:
        '200':
          description: A page of matching customers.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CustomerList'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '429':
          $ref: '#/components/responses/TooManyRequests'
  /Customer:
    get:
      operationId: getCustomerByUniqueId
      tags:
      - Customers
      summary: Get a customer by unique ID
      description: Retrieves a customer by its unique GUID.
      parameters:
      - $ref: '#/components/parameters/UniqueId'
      - $ref: '#/components/parameters/TenantId'
      - $ref: '#/components/parameters/IncludeAdditionalDetails'
      responses:
        '200':
          description: The requested customer.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Customer'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
    post:
      operationId: createCustomer
      tags:
      - Customers
      summary: Create a customer
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Customer'
      responses:
        '200':
          description: The created customer.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Customer'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '422':
          $ref: '#/components/responses/ValidationError'
    put:
      operationId: updateCustomer
      tags:
      - Customers
      summary: Update a customer
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Customer'
      responses:
        '200':
          description: The updated customer.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Customer'
        '401':
          $ref: '#/components/responses/Unauthorized'
    delete:
      operationId: deleteCustomer
      tags:
      - Customers
      summary: Delete a customer
      parameters:
      - $ref: '#/components/parameters/UniqueId'
      - $ref: '#/components/parameters/TenantId'
      responses:
        '200':
          description: Deletion confirmation.
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
  /Customer/GetById:
    get:
      operationId: getCustomerById
      tags:
      - Customers
      summary: Get a customer by integer ID
      parameters:
      - $ref: '#/components/parameters/IntId'
      - $ref: '#/components/parameters/TenantId'
      - $ref: '#/components/parameters/IncludeAdditionalDetails'
      responses:
        '200':
          description: The requested customer.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Customer'
        '401':
          $ref: '#/components/responses/Unauthorized'
  /Customer/SetStatus:
    put:
      operationId: setCustomerStatus
      tags:
      - Customers
      summary: Set customer status
      description: Activates or deactivates a customer.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SetStatusRequest'
      responses:
        '200':
          description: Status updated.
        '401':
          $ref: '#/components/responses/Unauthorized'
components:
  responses:
    ValidationError:
      description: The request payload failed validation.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: The requested resource was not found.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: Missing, invalid, or expired access token.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    TooManyRequests:
      description: Rate limit exceeded. Joblogic resource servers limit callers (by default up to 100 requests per minute) and respond with 429.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  parameters:
    TenantId:
      name: tenantId
      in: query
      required: true
      description: The caller's Joblogic tenant identifier (GUID).
      schema:
        type: string
        format: uuid
    UniqueId:
      name: id
      in: query
      required: true
      description: The resource's unique identifier (GUID).
      schema:
        type: string
        format: uuid
    IncludeAdditionalDetails:
      name: includeAdditionalDetails
      in: query
      required: false
      description: When true, expands nested/related detail in the response.
      schema:
        type: boolean
        default: false
    IntId:
      name: id
      in: query
      required: true
      description: The resource's integer identifier.
      schema:
        type: integer
        format: int64
  schemas:
    Error:
      type: object
      properties:
        code:
          type: string
        message:
          type: string
        details:
          type: object
          additionalProperties: true
    SearchRequest:
      type: object
      description: Common search envelope used by the /GetAll and /getall endpoints. Fields shown are representative; consult the live documentation for the exact filters supported per resource.
      properties:
        tenantId:
          type: string
          format: uuid
        searchTerm:
          type: string
        tags:
          type: array
          items:
            type: string
        activeStatus:
          type: string
          enum:
          - active
          - inactive
          - all
        pageNumber:
          type: integer
          default: 1
        pageSize:
          type: integer
          default: 50
    CustomerList:
      $ref: '#/components/schemas/PagedResult'
    PagedResult:
      type: object
      properties:
        data:
          type: array
          items:
            type: object
            additionalProperties: true
        pageNumber:
          type: integer
        pageSize:
          type: integer
        totalCount:
          type: integer
    Address:
      type: object
      properties:
        line1:
          type: string
        line2:
          type: string
        city:
          type: string
        county:
          type: string
        postcode:
          type: string
        country:
          type: string
    Customer:
      type: object
      properties:
        id:
          type: string
          format: uuid
        customerId:
          type: integer
          format: int64
        name:
          type: string
        accountReference:
          type: string
        telephone:
          type: string
        email:
          type: string
          format: email
        address:
          $ref: '#/components/schemas/Address'
        isActive:
          type: boolean
    SetStatusRequest:
      type: object
      properties:
        id:
          type: string
        tenantId:
          type: string
          format: uuid
        status:
          type: string
  securitySchemes:
    oauth2ClientCredentials:
      type: oauth2
      description: 'OAuth2 client-credentials grant against the Joblogic IdentityServer. The confirmed UAT token endpoint is https://uatidentityserver.joblogic.com/connect/token; the production IdentityServer token endpoint is provided to callers during onboarding. Send client_id, client_secret, grant_type=client_credentials, and the issued scope, then pass the returned access token as `Authorization: Bearer <access_token>`. Tokens expire after one hour.'
      flows:
        clientCredentials:
          tokenUrl: https://uatidentityserver.joblogic.com/connect/token
          scopes: {}