GetCustomerInfoResponse

public struct GetCustomerInfoResponse : Decodable, Sendable

Response returned when checking the status of a customer’s KYC information.

This response is returned by GET /customer requests in SEP-12 and provides the current status of the customer’s KYC process along with any fields that need to be provided or have already been submitted.

The response varies based on the customer’s current status:

  • ACCEPTED: Customer is fully KYC’d and approved
  • PROCESSING: KYC information is being processed
  • NEEDS_INFO: Additional information is required
  • REJECTED: Customer has been rejected

See SEP-12

  • id

    (optional) ID of the customer, if the customer has already been created via a PUT /customer request.

    Declaration

    Swift

    public let id: String?
  • Status of the customers KYC process.

    Declaration

    Swift

    public let status: String
  • (optional) An object containing the fields the anchor has not yet received for the given customer of the type provided in the request. Required for customers in the NEEDS_INFO status.

    Declaration

    Swift

    public let fields: [String : GetCustomerInfoField]?
  • (optional) An object containing the fields the anchor has received for the given customer. Required for customers whose information needs verification.

    Declaration

    Swift

    public let providedFields: [String : GetCustomerInfoProvidedField]?
  • (optional) Human readable message describing the current state of customer’s KYC process.

    Declaration

    Swift

    public let message: String?
  • Initializer - creates a new instance by decoding from the given decoder.

    Declaration

    Swift

    public init(from decoder: Decoder) throws

    Parameters

    decoder

    The decoder containing the data