kustomer-client
    Preparing search index...

    Function getCustomerById

    • Get customer by ID Retrieves a customer record based on the unique customer ID.

      Any one of the following roles is required for this endpoint:

      Legacy Role Equivalent Permission Set Role
      org.user.customer.read org.permission.customer.read

      Type Parameters

      • ThrowOnError extends boolean = true

      Returns RequestResult<
          {
              data: {
                  attributes: {
                      activeUsers: unknown[];
                      avatarUrl: null
                      | string;
                      birthdayAt: null | string;
                      conversationCounts: {
                          all: number;
                          done: number;
                          open: number;
                          snoozed: number;
                      };
                      createdAt: string;
                      displayColor: string;
                      displayIcon: string;
                      displayName: string;
                      emails: {
                          email: string;
                          id: null
                          | string;
                          type: string;
                          verified: boolean;
                      }[];
                      externalId: string;
                      externalIds: {
                          externalId: string;
                          id: null
                          | string;
                          verified: boolean;
                      }[];
                      gender: null
                      | string;
                      lastActivityAt: string;
                      lastConversation: {
                          id: string;
                          sentiment: { confidence: number; polarity: number };
                          tags: unknown[];
                      };
                      lastCustomerActivityAt: string;
                      lastMessageIn: { sentAt: string; sentiment: null
                      | string };
                      lastSeenAt: string;
                      locale: null | string;
                      locations: unknown[];
                      modifiedAt: string;
                      name: string;
                      phones: unknown[];
                      presence: string;
                      preview: {
                          previewAt: string;
                          subject: string;
                          text: string;
                          type: string;
                      };
                      progressiveStatus: string;
                      recentLocation: { updatedAt: string };
                      rev: number;
                      sentiment: { confidence: number; polarity: number };
                      sharedEmails: {
                          email: string;
                          id: null | string;
                          type: string;
                          verified: boolean;
                      }[];
                      sharedExternalIds: unknown[];
                      sharedPhones: unknown[];
                      sharedSocials: unknown[];
                      signedUpAt: null
                      | string;
                      socials: unknown[];
                      tags: unknown[];
                      timeZone: null | string;
                      updatedAt: string;
                      urls: unknown[];
                      username: null | string;
                      verified: boolean;
                      watchers: unknown[];
                  };
                  id: string;
                  links: { self: string };
                  relationships: {
                      messages: { links: { self: string } };
                      modifiedBy: {
                          data: { id: string; type: string };
                          links: { self: string };
                      };
                      org: { data: { id: string; type: string }; links: { self: string } };
                  };
                  type: string;
              };
          },
          unknown,
          ThrowOnError,
      >