lithic

package module
v0.98.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 12, 2025 License: Apache-2.0 Imports: 25 Imported by: 0

README

Lithic Go API Library

Go Reference

The Lithic Go library provides convenient access to the Lithic REST API from applications written in Go.

Installation

import (
	"github.com/lithic-com/lithic-go" // imported as lithic
)

Or to pin the version:

go get -u 'github.com/lithic-com/[email protected]'

Requirements

This library requires Go 1.22+.

Usage

The full API of this library can be found in api.md.

package main

import (
	"context"
	"fmt"

	"github.com/lithic-com/lithic-go"
	"github.com/lithic-com/lithic-go/option"
)

func main() {
	client := lithic.NewClient(
		option.WithAPIKey("My Lithic API Key"), // defaults to os.LookupEnv("LITHIC_API_KEY")
		option.WithEnvironmentSandbox(),        // defaults to option.WithEnvironmentProduction()
	)
	card, err := client.Cards.New(context.TODO(), lithic.CardNewParams{
		Type: lithic.F(lithic.CardNewParamsTypeSingleUse),
	})
	if err != nil {
		panic(err.Error())
	}
	fmt.Printf("%+v\n", card.Token)
}

Request fields

All request parameters are wrapped in a generic Field type, which we use to distinguish zero values from null or omitted fields.

This prevents accidentally sending a zero value if you forget a required parameter, and enables explicitly sending null, false, '', or 0 on optional parameters. Any field not specified is not sent.

To construct fields with values, use the helpers String(), Int(), Float(), or most commonly, the generic F[T](). To send a null, use Null[T](), and to send a nonconforming value, use Raw[T](any). For example:

params := FooParams{
	Name: lithic.F("hello"),

	// Explicitly send `"description": null`
	Description: lithic.Null[string](),

	Point: lithic.F(lithic.Point{
		X: lithic.Int(0),
		Y: lithic.Int(1),

		// In cases where the API specifies a given type,
		// but you want to send something else, use `Raw`:
		Z: lithic.Raw[int64](0.01), // sends a float
	}),
}
Response objects

All fields in response structs are value types (not pointers or wrappers).

If a given field is null, not present, or invalid, the corresponding field will simply be its zero value.

All response structs also include a special JSON field, containing more detailed information about each property, which you can use like so:

if res.Name == "" {
	// true if `"name"` is either not present or explicitly null
	res.JSON.Name.IsNull()

	// true if the `"name"` key was not present in the response JSON at all
	res.JSON.Name.IsMissing()

	// When the API returns data that cannot be coerced to the expected type:
	if res.JSON.Name.IsInvalid() {
		raw := res.JSON.Name.Raw()

		legacyName := struct{
			First string `json:"first"`
			Last  string `json:"last"`
		}{}
		json.Unmarshal([]byte(raw), &legacyName)
		name = legacyName.First + " " + legacyName.Last
	}
}

These .JSON structs also include an Extras map containing any properties in the json response that were not specified in the struct. This can be useful for API features not yet present in the SDK.

body := res.JSON.ExtraFields["my_unexpected_field"].Raw()
RequestOptions

This library uses the functional options pattern. Functions defined in the option package return a RequestOption, which is a closure that mutates a RequestConfig. These options can be supplied to the client or at individual requests. For example:

client := lithic.NewClient(
	// Adds a header to every request made by the client
	option.WithHeader("X-Some-Header", "custom_header_info"),
)

client.Cards.New(context.TODO(), ...,
	// Override the header
	option.WithHeader("X-Some-Header", "some_other_custom_header_info"),
	// Add an undocumented field to the request body, using sjson syntax
	option.WithJSONSet("some.json.path", map[string]string{"my": "object"}),
)

See the full list of request options.

Pagination

This library provides some conveniences for working with paginated list endpoints.

You can use .ListAutoPaging() methods to iterate through items across all pages:

iter := client.Cards.ListAutoPaging(context.TODO(), lithic.CardListParams{})
// Automatically fetches more pages as needed.
for iter.Next() {
	nonPCICard := iter.Current()
	fmt.Printf("%+v\n", nonPCICard)
}
if err := iter.Err(); err != nil {
	panic(err.Error())
}

Or you can use simple .List() methods to fetch a single page and receive a standard response object with additional helper methods like .GetNextPage(), e.g.:

page, err := client.Cards.List(context.TODO(), lithic.CardListParams{})
for page != nil {
	for _, card := range page.Data {
		fmt.Printf("%+v\n", card)
	}
	page, err = page.GetNextPage()
}
if err != nil {
	panic(err.Error())
}
Errors

When the API returns a non-success status code, we return an error with type *lithic.Error. This contains the StatusCode, *http.Request, and *http.Response values of the request, as well as the JSON of the error body (much like other response objects in the SDK).

To handle errors, we recommend that you use the errors.As pattern:

_, err := client.Cards.New(context.TODO(), lithic.CardNewParams{
	Type: lithic.F(lithic.CardNewParamsTypeMerchantLocked),
})
if err != nil {
	var apierr *lithic.Error
	if errors.As(err, &apierr) {
		println(string(apierr.DumpRequest(true)))  // Prints the serialized HTTP request
		println(string(apierr.DumpResponse(true))) // Prints the serialized HTTP response
		println(apierr.Message)                    // Invalid parameter(s): type
		println(apierr.DebuggingRequestID)         // 94d5e915-xxxx-4cee-a4f5-2xd6ebd279ac
	}
	panic(err.Error()) // GET "/v1/cards": 400 Bad Request { ... }
}

When other errors occur, they are returned unwrapped; for example, if HTTP transport fails, you might receive *url.Error wrapping *net.OpError.

Timeouts

Requests do not time out by default; use context to configure a timeout for a request lifecycle.

Note that if a request is retried, the context timeout does not start over. To set a per-retry timeout, use option.WithRequestTimeout().

// This sets the timeout for the request, including all the retries.
ctx, cancel := context.WithTimeout(context.Background(), 5*time.Minute)
defer cancel()
client.Cards.List(
	ctx,
	lithic.CardListParams{
		PageSize: lithic.F(int64(10)),
	},
	// This sets the per-retry timeout
	option.WithRequestTimeout(20*time.Second),
)
File uploads

Request parameters that correspond to file uploads in multipart requests are typed as param.Field[io.Reader]. The contents of the io.Reader will by default be sent as a multipart form part with the file name of "anonymous_file" and content-type of "application/octet-stream".

The file name and content-type can be customized by implementing Name() string or ContentType() string on the run-time type of io.Reader. Note that os.File implements Name() string, so a file returned by os.Open will be sent with the file name on disk.

We also provide a helper lithic.FileParam(reader io.Reader, filename string, contentType string) which can be used to wrap any io.Reader with the appropriate file name and content type.

Retries

Certain errors will be automatically retried 2 times by default, with a short exponential backoff. We retry by default all connection errors, 408 Request Timeout, 409 Conflict, 429 Rate Limit, and >=500 Internal errors.

You can use the WithMaxRetries option to configure or disable this:

// Configure the default for all requests:
client := lithic.NewClient(
	option.WithMaxRetries(0), // default is 2
)

// Override per-request:
client.Cards.List(
	context.TODO(),
	lithic.CardListParams{
		PageSize: lithic.F(int64(10)),
	},
	option.WithMaxRetries(5),
)
Accessing raw response data (e.g. response headers)

You can access the raw HTTP response data by using the option.WithResponseInto() request option. This is useful when you need to examine response headers, status codes, or other details.

// Create a variable to store the HTTP response
var response *http.Response
card, err := client.Cards.New(
	context.TODO(),
	lithic.CardNewParams{
		Type: lithic.F(lithic.CardNewParamsTypeSingleUse),
	},
	option.WithResponseInto(&response),
)
if err != nil {
	// handle error
}
fmt.Printf("%+v\n", card)

fmt.Printf("Status Code: %d\n", response.StatusCode)
fmt.Printf("Headers: %+#v\n", response.Header)
Making custom/undocumented requests

This library is typed for convenient access to the documented API. If you need to access undocumented endpoints, params, or response properties, the library can still be used.

Undocumented endpoints

To make requests to undocumented endpoints, you can use client.Get, client.Post, and other HTTP verbs. RequestOptions on the client, such as retries, will be respected when making these requests.

var (
    // params can be an io.Reader, a []byte, an encoding/json serializable object,
    // or a "…Params" struct defined in this library.
    params map[string]interface{}

    // result can be an []byte, *http.Response, a encoding/json deserializable object,
    // or a model defined in this library.
    result *http.Response
)
err := client.Post(context.Background(), "/unspecified", params, &result)
if err != nil {
    …
}
Undocumented request params

To make requests using undocumented parameters, you may use either the option.WithQuerySet() or the option.WithJSONSet() methods.

params := FooNewParams{
    ID:   lithic.F("id_xxxx"),
    Data: lithic.F(FooNewParamsData{
        FirstName: lithic.F("John"),
    }),
}
client.Foo.New(context.Background(), params, option.WithJSONSet("data.last_name", "Doe"))
Undocumented response properties

To access undocumented response properties, you may either access the raw JSON of the response as a string with result.JSON.RawJSON(), or get the raw JSON of a particular field on the result with result.JSON.Foo.Raw().

Any fields that are not present on the response struct will be saved and can be accessed by result.JSON.ExtraFields() which returns the extra fields as a map[string]Field.

Webhooks

Lithic uses webhooks to notify your application when events happen. The library provides signature verification using the standard-webhooks dependency which is already included.

Parsing and verifying webhooks
// Verifies signature and returns typed event
event, err := client.Webhooks.Parse(
	payload,
	request.Header,
	// optionally pass option.WithWebhookSecret(secret), otherwise reads from client config
)
if err != nil {
	log.Fatal(err)
}

// Use type switch on AsUnion() to handle different event types
switch e := event.AsUnion().(type) {
case lithic.CardCreatedWebhookEvent:
	fmt.Printf("Card created: %s\n", e.CardToken)
case lithic.AccountHolderCreatedWebhookEvent:
	fmt.Printf("Account holder created: %s\n", e.Token)
default:
	fmt.Printf("Unknown event type: %T\n", e)
}
Parsing without verification
// Parse only - skips signature verification (not recommended for production)
event, err := client.Webhooks.ParseUnsafe(payload)
Middleware

We provide option.WithMiddleware which applies the given middleware to requests.

func Logger(req *http.Request, next option.MiddlewareNext) (res *http.Response, err error) {
	// Before the request
	start := time.Now()
	LogReq(req)

	// Forward the request to the next handler
	res, err = next(req)

	// Handle stuff after the request
	end := time.Now()
	LogRes(res, err, start - end)

    return res, err
}

client := lithic.NewClient(
	option.WithMiddleware(Logger),
)

When multiple middlewares are provided as variadic arguments, the middlewares are applied left to right. If option.WithMiddleware is given multiple times, for example first in the client then the method, the middleware in the client will run first and the middleware given in the method will run next.

You may also replace the default http.Client with option.WithHTTPClient(client). Only one http client is accepted (this overwrites any previous client) and receives requests after any middleware has been applied.

Semantic versioning

This package generally follows SemVer conventions, though certain backwards-incompatible changes may be released as minor versions:

  1. Changes to library internals which are technically public but not intended or documented for external use. (Please open a GitHub issue to let us know if you are relying on such internals.)
  2. Changes that we do not expect to impact the vast majority of users in practice.

We take backwards-compatibility seriously and work hard to ensure you can rely on a smooth upgrade experience.

We are keen for your feedback; please open an issue with questions, bugs, or suggestions.

Contributing

See the contributing documentation.

Documentation

Index

Constants

View Source
const DocumentDocumentTypeArticlesOfIncorporation = shared.DocumentDocumentTypeArticlesOfIncorporation

This is an alias to an internal value.

View Source
const DocumentDocumentTypeArticlesOfOrganization = shared.DocumentDocumentTypeArticlesOfOrganization

This is an alias to an internal value.

View Source
const DocumentDocumentTypeBankStatement = shared.DocumentDocumentTypeBankStatement

This is an alias to an internal value.

View Source
const DocumentDocumentTypeBylaws = shared.DocumentDocumentTypeBylaws

This is an alias to an internal value.

View Source
const DocumentDocumentTypeCertificateOfFormation = shared.DocumentDocumentTypeCertificateOfFormation

This is an alias to an internal value.

View Source
const DocumentDocumentTypeCertificateOfGoodStanding = shared.DocumentDocumentTypeCertificateOfGoodStanding

This is an alias to an internal value.

View Source
const DocumentDocumentTypeDriversLicense = shared.DocumentDocumentTypeDriversLicense

This is an alias to an internal value.

View Source
const DocumentDocumentTypeEinLetter = shared.DocumentDocumentTypeEinLetter

This is an alias to an internal value.

View Source
const DocumentDocumentTypeFincenBoiReport = shared.DocumentDocumentTypeFincenBoiReport

This is an alias to an internal value.

View Source
const DocumentDocumentTypeGovernmentBusinessLicense = shared.DocumentDocumentTypeGovernmentBusinessLicense

This is an alias to an internal value.

View Source
const DocumentDocumentTypeItinLetter = shared.DocumentDocumentTypeItinLetter

This is an alias to an internal value.

View Source
const DocumentDocumentTypeOperatingAgreement = shared.DocumentDocumentTypeOperatingAgreement

This is an alias to an internal value.

View Source
const DocumentDocumentTypePartnershipAgreement = shared.DocumentDocumentTypePartnershipAgreement

This is an alias to an internal value.

View Source
const DocumentDocumentTypePassport = shared.DocumentDocumentTypePassport

This is an alias to an internal value.

View Source
const DocumentDocumentTypePassportCard = shared.DocumentDocumentTypePassportCard

This is an alias to an internal value.

View Source
const DocumentDocumentTypeSs4Form = shared.DocumentDocumentTypeSs4Form

This is an alias to an internal value.

View Source
const DocumentDocumentTypeSsnCard = shared.DocumentDocumentTypeSsnCard

This is an alias to an internal value.

View Source
const DocumentDocumentTypeTaxReturn = shared.DocumentDocumentTypeTaxReturn

This is an alias to an internal value.

View Source
const DocumentDocumentTypeUtilityBillStatement = shared.DocumentDocumentTypeUtilityBillStatement

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsImageTypeBack = shared.DocumentRequiredDocumentUploadsImageTypeBack

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsImageTypeFront = shared.DocumentRequiredDocumentUploadsImageTypeFront

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusAccepted = shared.DocumentRequiredDocumentUploadsStatusAccepted

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusPartialApproval = shared.DocumentRequiredDocumentUploadsStatusPartialApproval

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusPendingUpload = shared.DocumentRequiredDocumentUploadsStatusPendingUpload

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusReasonDocumentExpired = shared.DocumentRequiredDocumentUploadsStatusReasonDocumentExpired

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusReasonDocumentIssuedGreaterThan30Days = shared.DocumentRequiredDocumentUploadsStatusReasonDocumentIssuedGreaterThan30Days

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusReasonDocumentMissingRequiredData = shared.DocumentRequiredDocumentUploadsStatusReasonDocumentMissingRequiredData

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusReasonDocumentTypeNotSupported = shared.DocumentRequiredDocumentUploadsStatusReasonDocumentTypeNotSupported

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusReasonDocumentUploadTooBlurry = shared.DocumentRequiredDocumentUploadsStatusReasonDocumentUploadTooBlurry

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusReasonFileSizeTooLarge = shared.DocumentRequiredDocumentUploadsStatusReasonFileSizeTooLarge

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusReasonInvalidDocumentType = shared.DocumentRequiredDocumentUploadsStatusReasonInvalidDocumentType

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusReasonInvalidDocumentUpload = shared.DocumentRequiredDocumentUploadsStatusReasonInvalidDocumentUpload

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusReasonInvalidEntity = shared.DocumentRequiredDocumentUploadsStatusReasonInvalidEntity

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusReasonUnknownError = shared.DocumentRequiredDocumentUploadsStatusReasonUnknownError

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusReasonUnknownFailureReason = shared.DocumentRequiredDocumentUploadsStatusReasonUnknownFailureReason

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusRejected = shared.DocumentRequiredDocumentUploadsStatusRejected

This is an alias to an internal value.

View Source
const DocumentRequiredDocumentUploadsStatusUploaded = shared.DocumentRequiredDocumentUploadsStatusUploaded

This is an alias to an internal value.

View Source
const FinancialEventResultApproved = shared.FinancialEventResultApproved

This is an alias to an internal value.

View Source
const FinancialEventResultDeclined = shared.FinancialEventResultDeclined

This is an alias to an internal value.

View Source
const FinancialEventTypeACHOriginationCancelled = shared.FinancialEventTypeACHOriginationCancelled

This is an alias to an internal value.

View Source
const FinancialEventTypeACHOriginationInitiated = shared.FinancialEventTypeACHOriginationInitiated

This is an alias to an internal value.

View Source
const FinancialEventTypeACHOriginationProcessed = shared.FinancialEventTypeACHOriginationProcessed

This is an alias to an internal value.

View Source
const FinancialEventTypeACHOriginationRejected = shared.FinancialEventTypeACHOriginationRejected

This is an alias to an internal value.

View Source
const FinancialEventTypeACHOriginationReleased = shared.FinancialEventTypeACHOriginationReleased

This is an alias to an internal value.

View Source
const FinancialEventTypeACHOriginationReviewed = shared.FinancialEventTypeACHOriginationReviewed

This is an alias to an internal value.

View Source
const FinancialEventTypeACHOriginationSettled = shared.FinancialEventTypeACHOriginationSettled

This is an alias to an internal value.

View Source
const FinancialEventTypeACHReceiptProcessed = shared.FinancialEventTypeACHReceiptProcessed

This is an alias to an internal value.

View Source
const FinancialEventTypeACHReceiptReleased = shared.FinancialEventTypeACHReceiptReleased

This is an alias to an internal value.

View Source
const FinancialEventTypeACHReceiptSettled = shared.FinancialEventTypeACHReceiptSettled

This is an alias to an internal value.

View Source
const FinancialEventTypeACHReturnInitiated = shared.FinancialEventTypeACHReturnInitiated

This is an alias to an internal value.

View Source
const FinancialEventTypeACHReturnProcessed = shared.FinancialEventTypeACHReturnProcessed

This is an alias to an internal value.

View Source
const FinancialEventTypeACHReturnRejected = shared.FinancialEventTypeACHReturnRejected

This is an alias to an internal value.

View Source
const FinancialEventTypeACHReturnSettled = shared.FinancialEventTypeACHReturnSettled

This is an alias to an internal value.

View Source
const FinancialEventTypeAnnual = shared.FinancialEventTypeAnnual

This is an alias to an internal value.

View Source
const FinancialEventTypeAnnualReversal = shared.FinancialEventTypeAnnualReversal

This is an alias to an internal value.

View Source
const FinancialEventTypeAuthorization = shared.FinancialEventTypeAuthorization

This is an alias to an internal value.

View Source
const FinancialEventTypeAuthorizationAdvice = shared.FinancialEventTypeAuthorizationAdvice

This is an alias to an internal value.

View Source
const FinancialEventTypeAuthorizationExpiry = shared.FinancialEventTypeAuthorizationExpiry

This is an alias to an internal value.

View Source
const FinancialEventTypeAuthorizationReversal = shared.FinancialEventTypeAuthorizationReversal

This is an alias to an internal value.

View Source
const FinancialEventTypeBalanceInquiry = shared.FinancialEventTypeBalanceInquiry

This is an alias to an internal value.

View Source
const FinancialEventTypeBillingError = shared.FinancialEventTypeBillingError

This is an alias to an internal value.

View Source
const FinancialEventTypeBillingErrorReversal = shared.FinancialEventTypeBillingErrorReversal

This is an alias to an internal value.

View Source
const FinancialEventTypeCardToCard = shared.FinancialEventTypeCardToCard

This is an alias to an internal value.

View Source
const FinancialEventTypeCashBack = shared.FinancialEventTypeCashBack

This is an alias to an internal value.

View Source
const FinancialEventTypeCashBackReversal = shared.FinancialEventTypeCashBackReversal

This is an alias to an internal value.

View Source
const FinancialEventTypeClearing = shared.FinancialEventTypeClearing

This is an alias to an internal value.

View Source
const FinancialEventTypeCollection = shared.FinancialEventTypeCollection

This is an alias to an internal value.

View Source
const FinancialEventTypeCorrectionCredit = shared.FinancialEventTypeCorrectionCredit

This is an alias to an internal value.

View Source
const FinancialEventTypeCorrectionDebit = shared.FinancialEventTypeCorrectionDebit

This is an alias to an internal value.

View Source
const FinancialEventTypeCreditAuthorization = shared.FinancialEventTypeCreditAuthorization

This is an alias to an internal value.

View Source
const FinancialEventTypeCreditAuthorizationAdvice = shared.FinancialEventTypeCreditAuthorizationAdvice

This is an alias to an internal value.

View Source
const FinancialEventTypeCurrencyConversion = shared.FinancialEventTypeCurrencyConversion

This is an alias to an internal value.

View Source
const FinancialEventTypeCurrencyConversionReversal = shared.FinancialEventTypeCurrencyConversionReversal

This is an alias to an internal value.

View Source
const FinancialEventTypeDisputeWon = shared.FinancialEventTypeDisputeWon

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalACHCanceled = shared.FinancialEventTypeExternalACHCanceled

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalACHInitiated = shared.FinancialEventTypeExternalACHInitiated

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalACHReleased = shared.FinancialEventTypeExternalACHReleased

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalACHReversed = shared.FinancialEventTypeExternalACHReversed

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalACHSettled = shared.FinancialEventTypeExternalACHSettled

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalCheckCanceled = shared.FinancialEventTypeExternalCheckCanceled

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalCheckInitiated = shared.FinancialEventTypeExternalCheckInitiated

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalCheckReleased = shared.FinancialEventTypeExternalCheckReleased

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalCheckReversed = shared.FinancialEventTypeExternalCheckReversed

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalCheckSettled = shared.FinancialEventTypeExternalCheckSettled

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalFednowCanceled = shared.FinancialEventTypeExternalFednowCanceled

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalFednowInitiated = shared.FinancialEventTypeExternalFednowInitiated

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalFednowReleased = shared.FinancialEventTypeExternalFednowReleased

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalFednowReversed = shared.FinancialEventTypeExternalFednowReversed

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalFednowSettled = shared.FinancialEventTypeExternalFednowSettled

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalRtpCanceled = shared.FinancialEventTypeExternalRtpCanceled

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalRtpInitiated = shared.FinancialEventTypeExternalRtpInitiated

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalRtpReleased = shared.FinancialEventTypeExternalRtpReleased

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalRtpReversed = shared.FinancialEventTypeExternalRtpReversed

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalRtpSettled = shared.FinancialEventTypeExternalRtpSettled

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalTransferCanceled = shared.FinancialEventTypeExternalTransferCanceled

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalTransferInitiated = shared.FinancialEventTypeExternalTransferInitiated

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalTransferReleased = shared.FinancialEventTypeExternalTransferReleased

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalTransferReversed = shared.FinancialEventTypeExternalTransferReversed

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalTransferSettled = shared.FinancialEventTypeExternalTransferSettled

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalWireCanceled = shared.FinancialEventTypeExternalWireCanceled

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalWireInitiated = shared.FinancialEventTypeExternalWireInitiated

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalWireReleased = shared.FinancialEventTypeExternalWireReleased

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalWireReversed = shared.FinancialEventTypeExternalWireReversed

This is an alias to an internal value.

View Source
const FinancialEventTypeExternalWireSettled = shared.FinancialEventTypeExternalWireSettled

This is an alias to an internal value.

View Source
const FinancialEventTypeFinancialAuthorization = shared.FinancialEventTypeFinancialAuthorization

This is an alias to an internal value.

View Source
const FinancialEventTypeFinancialCreditAuthorization = shared.FinancialEventTypeFinancialCreditAuthorization

This is an alias to an internal value.

View Source
const FinancialEventTypeInterest = shared.FinancialEventTypeInterest

This is an alias to an internal value.

View Source
const FinancialEventTypeInterestReversal = shared.FinancialEventTypeInterestReversal

This is an alias to an internal value.

View Source
const FinancialEventTypeInternalAdjustment = shared.FinancialEventTypeInternalAdjustment

This is an alias to an internal value.

View Source
const FinancialEventTypeLatePayment = shared.FinancialEventTypeLatePayment

This is an alias to an internal value.

View Source
const FinancialEventTypeLatePaymentReversal = shared.FinancialEventTypeLatePaymentReversal

This is an alias to an internal value.

View Source
const FinancialEventTypeLithicNetworkPayment = shared.FinancialEventTypeLithicNetworkPayment

This is an alias to an internal value.

View Source
const FinancialEventTypeLossWriteOff = shared.FinancialEventTypeLossWriteOff

This is an alias to an internal value.

View Source
const FinancialEventTypeMonthly = shared.FinancialEventTypeMonthly

This is an alias to an internal value.

View Source
const FinancialEventTypeMonthlyReversal = shared.FinancialEventTypeMonthlyReversal

This is an alias to an internal value.

View Source
const FinancialEventTypeProvisionalCredit = shared.FinancialEventTypeProvisionalCredit

This is an alias to an internal value.

View Source
const FinancialEventTypeProvisionalCreditReversal = shared.FinancialEventTypeProvisionalCreditReversal

This is an alias to an internal value.

View Source
const FinancialEventTypeQuarterly = shared.FinancialEventTypeQuarterly

This is an alias to an internal value.

View Source
const FinancialEventTypeQuarterlyReversal = shared.FinancialEventTypeQuarterlyReversal

This is an alias to an internal value.

View Source
const FinancialEventTypeReturn = shared.FinancialEventTypeReturn

This is an alias to an internal value.

View Source
const FinancialEventTypeReturnReversal = shared.FinancialEventTypeReturnReversal

This is an alias to an internal value.

View Source
const FinancialEventTypeReturnedPayment = shared.FinancialEventTypeReturnedPayment

This is an alias to an internal value.

View Source
const FinancialEventTypeReturnedPaymentReversal = shared.FinancialEventTypeReturnedPaymentReversal

This is an alias to an internal value.

View Source
const FinancialEventTypeService = shared.FinancialEventTypeService

This is an alias to an internal value.

View Source
const FinancialEventTypeTransfer = shared.FinancialEventTypeTransfer

This is an alias to an internal value.

View Source
const FinancialEventTypeTransferInsufficientFunds = shared.FinancialEventTypeTransferInsufficientFunds

This is an alias to an internal value.

Variables

This section is empty.

Functions

func Bool added in v0.6.5

func Bool(value bool) param.Field[bool]

Bool is a param field helper which helps specify bools.

func DefaultClientOptions added in v0.70.0

func DefaultClientOptions() []option.RequestOption

DefaultClientOptions read from the environment (LITHIC_API_KEY, LITHIC_WEBHOOK_SECRET, LITHIC_BASE_URL). This should be used to initialize new clients.

func F

func F[T any](value T) param.Field[T]

F is a param field helper used to initialize a param.Field generic struct. This helps specify null, zero values, and overrides, as well as normal values. You can read more about this in our README.

func FileParam added in v0.28.0

func FileParam(reader io.Reader, filename string, contentType string) param.Field[io.Reader]

FileParam is a param field helper which helps files with a mime content-type.

func Float

func Float(value float64) param.Field[float64]

Float is a param field helper which helps specify floats.

func Int

func Int(value int64) param.Field[int64]

Int is a param field helper which helps specify integers. This is particularly helpful when specifying integer constants for fields.

func Null

func Null[T any]() param.Field[T]

Null is a param field helper which explicitly sends null to the API.

func Raw

func Raw[T any](value any) param.Field[T]

Raw is a param field helper for specifying values for fields when the type you are looking to send is different from the type that is specified in the SDK. For example, if the type of the field is an integer, but you want to send a float, you could do that by setting the corresponding field with Raw[int](0.5).

func String

func String(value string) param.Field[string]

String is a param field helper which helps specify strings.

Types

type APIStatus

type APIStatus struct {
	Message string        `json:"message"`
	JSON    apiStatusJSON `json:"-"`
}

func (*APIStatus) UnmarshalJSON

func (r *APIStatus) UnmarshalJSON(data []byte) (err error)

type Account

type Account struct {
	// Globally unique identifier for the account. This is the same as the
	// account_token returned by the enroll endpoint. If using this parameter, do not
	// include pagination.
	Token string `json:"token,required" format:"uuid"`
	// Timestamp of when the account was created.
	Created time.Time `json:"created,required,nullable" format:"date-time"`
	// Spend limit information for the user containing the daily, monthly, and lifetime
	// spend limit of the account. Any charges to a card owned by this account will be
	// declined once their transaction volume has surpassed the value in the applicable
	// time limit (rolling). A lifetime limit of 0 indicates that the lifetime limit
	// feature is disabled.
	SpendLimit AccountSpendLimit `json:"spend_limit,required"`
	// Account state:
	//
	//   - `ACTIVE` - Account is able to transact and create new cards.
	//   - `PAUSED` - Account will not be able to transact or create new cards. It can be
	//     set back to `ACTIVE`.
	//   - `CLOSED` - Account will not be able to transact or create new cards. `CLOSED`
	//     accounts are unable to be transitioned to `ACTIVE` or `PAUSED` states.
	//     Accounts can be manually set to `CLOSED`, or this can be done by Lithic due to
	//     failure to pass KYB/KYC or for risk/compliance reasons. Please contact
	//     [[email protected]](mailto:[email protected]) if you believe this was done
	//     by mistake.
	State         AccountState         `json:"state,required"`
	AccountHolder AccountAccountHolder `json:"account_holder"`
	// List of identifiers for the Auth Rule(s) that are applied on the account. This
	// field is deprecated and will no longer be populated in the `account_holder`
	// object. The key will be removed from the schema in a future release. Use the
	// `/auth_rules` endpoints to fetch Auth Rule information instead.
	//
	// Deprecated: deprecated
	AuthRuleTokens []string `json:"auth_rule_tokens"`
	// 3-character alphabetic ISO 4217 code for the currency of the cardholder.
	CardholderCurrency string `json:"cardholder_currency"`
	// Additional context or information related to the account.
	Comment string `json:"comment"`
	// Account state substatus values:
	//
	//   - `FRAUD_IDENTIFIED` - The account has been recognized as being created or used
	//     with stolen or fabricated identity information, encompassing both true
	//     identity theft and synthetic identities.
	//   - `SUSPICIOUS_ACTIVITY` - The account has exhibited suspicious behavior, such as
	//     unauthorized access or fraudulent transactions, necessitating further
	//     investigation.
	//   - `RISK_VIOLATION` - The account has been involved in deliberate misuse by the
	//     legitimate account holder. Examples include disputing valid transactions
	//     without cause, falsely claiming non-receipt of goods, or engaging in
	//     intentional bust-out schemes to exploit account services.
	//   - `END_USER_REQUEST` - The account holder has voluntarily requested the closure
	//     of the account for personal reasons. This encompasses situations such as
	//     bankruptcy, other financial considerations, or the account holder's death.
	//   - `ISSUER_REQUEST` - The issuer has initiated the closure of the account due to
	//     business strategy, risk management, inactivity, product changes, regulatory
	//     concerns, or violations of terms and conditions.
	//   - `NOT_ACTIVE` - The account has not had any transactions or payment activity
	//     within a specified period. This status applies to accounts that are paused or
	//     closed due to inactivity.
	//   - `INTERNAL_REVIEW` - The account is temporarily paused pending further internal
	//     review. In future implementations, this status may prevent clients from
	//     activating the account via APIs until the review is completed.
	//   - `OTHER` - The reason for the account's current status does not fall into any
	//     of the above categories. A comment should be provided to specify the
	//     particular reason.
	Substatus AccountSubstatus `json:"substatus"`
	// Deprecated: deprecated
	VerificationAddress AccountVerificationAddress `json:"verification_address"`
	JSON                accountJSON                `json:"-"`
}

func (*Account) UnmarshalJSON

func (r *Account) UnmarshalJSON(data []byte) (err error)

type AccountAccountHolder

type AccountAccountHolder struct {
	// Globally unique identifier for the account holder.
	Token string `json:"token,required"`
	// Only applicable for customers using the KYC-Exempt workflow to enroll authorized
	// users of businesses. Account_token of the enrolled business associated with an
	// enrolled AUTHORIZED_USER individual.
	BusinessAccountToken string `json:"business_account_token,required"`
	// Email address.
	Email string `json:"email,required"`
	// Phone number of the individual.
	PhoneNumber string                   `json:"phone_number,required"`
	JSON        accountAccountHolderJSON `json:"-"`
}

func (*AccountAccountHolder) UnmarshalJSON

func (r *AccountAccountHolder) UnmarshalJSON(data []byte) (err error)

type AccountActivityGetTransactionResponse added in v0.87.0

type AccountActivityGetTransactionResponse struct {
	// Unique identifier for the transaction
	Token string `json:"token,required" format:"uuid"`
	// ISO 8601 timestamp of when the transaction was created
	Created time.Time `json:"created,required" format:"date-time"`
	// The status of the transaction
	Status AccountActivityGetTransactionResponseStatus `json:"status,required"`
	// ISO 8601 timestamp of when the transaction was last updated
	Updated time.Time `json:"updated,required" format:"date-time"`
	// The token for the account associated with this transaction.
	AccountToken string `json:"account_token" format:"uuid"`
	// Fee assessed by the merchant and paid for by the cardholder in the smallest unit
	// of the currency. Will be zero if no fee is assessed. Rebates may be transmitted
	// as a negative value to indicate credited fees.
	AcquirerFee int64 `json:"acquirer_fee,nullable"`
	// Unique identifier assigned to a transaction by the acquirer that can be used in
	// dispute and chargeback filing. This field has been deprecated in favor of the
	// `acquirer_reference_number` that resides in the event-level `network_info`.
	//
	// Deprecated: deprecated
	AcquirerReferenceNumber string `json:"acquirer_reference_number,nullable"`
	// When the transaction is pending, this represents the authorization amount of the
	// transaction in the anticipated settlement currency. Once the transaction has
	// settled, this field represents the settled amount in the settlement currency.
	//
	// Deprecated: deprecated
	Amount int64 `json:"amount"`
	// This field can have the runtime type of [TransactionAmounts].
	Amounts interface{} `json:"amounts"`
	// The authorization amount of the transaction in the anticipated settlement
	// currency.
	//
	// Deprecated: deprecated
	AuthorizationAmount int64 `json:"authorization_amount,nullable"`
	// A fixed-width 6-digit numeric identifier that can be used to identify a
	// transaction with networks.
	AuthorizationCode string `json:"authorization_code,nullable"`
	// This field can have the runtime type of [TransactionAvs].
	Avs interface{} `json:"avs"`
	// Token for the card used in this transaction.
	CardToken                string                   `json:"card_token" format:"uuid"`
	CardholderAuthentication CardholderAuthentication `json:"cardholder_authentication,nullable"`
	// Transaction category
	Category AccountActivityGetTransactionResponseCategory `json:"category"`
	// Currency of the transaction, represented in ISO 4217 format
	Currency string `json:"currency"`
	// Transaction descriptor
	Descriptor string `json:"descriptor"`
	// Transfer direction
	Direction AccountActivityGetTransactionResponseDirection `json:"direction"`
	// This field can have the runtime type of [[]shared.FinancialEvent],
	// [[]BookTransferResponseEvent], [[]TransactionEvent], [[]PaymentEvent],
	// [[]ExternalPaymentEvent], [[]ManagementOperationTransactionEvent].
	Events interface{} `json:"events"`
	// Expected release date for the transaction
	ExpectedReleaseDate time.Time `json:"expected_release_date,nullable" format:"date"`
	// External bank account token
	ExternalBankAccountToken string `json:"external_bank_account_token,nullable" format:"uuid"`
	// External ID defined by the customer
	ExternalID string `json:"external_id,nullable"`
	// External resource associated with the management operation
	ExternalResource ExternalResource `json:"external_resource,nullable"`
	// INTERNAL - Financial Transaction
	Family AccountActivityGetTransactionResponseFamily `json:"family"`
	// Financial account token associated with the transaction
	FinancialAccountToken string `json:"financial_account_token,nullable" format:"uuid"`
	// Globally unique identifier for the financial account or card that will send the
	// funds. Accepted type dependent on the program's use case
	FromFinancialAccountToken string          `json:"from_financial_account_token" format:"uuid"`
	Merchant                  shared.Merchant `json:"merchant"`
	// Analogous to the 'amount', but in the merchant currency.
	//
	// Deprecated: deprecated
	MerchantAmount int64 `json:"merchant_amount,nullable"`
	// Analogous to the 'authorization_amount', but in the merchant currency.
	//
	// Deprecated: deprecated
	MerchantAuthorizationAmount int64 `json:"merchant_authorization_amount,nullable"`
	// 3-character alphabetic ISO 4217 code for the local currency of the transaction.
	//
	// Deprecated: deprecated
	MerchantCurrency string `json:"merchant_currency"`
	// Transfer method
	Method AccountActivityGetTransactionResponseMethod `json:"method"`
	// This field can have the runtime type of [PaymentMethodAttributes].
	MethodAttributes interface{} `json:"method_attributes"`
	// Card network of the authorization. Value is `UNKNOWN` when Lithic cannot
	// determine the network code from the upstream provider.
	Network AccountActivityGetTransactionResponseNetwork `json:"network,nullable"`
	// Network-provided score assessing risk level associated with a given
	// authorization. Scores are on a range of 0-999, with 0 representing the lowest
	// risk and 999 representing the highest risk. For Visa transactions, where the raw
	// score has a range of 0-99, Lithic will normalize the score by multiplying the
	// raw score by 10x.
	NetworkRiskScore int64                                            `json:"network_risk_score,nullable"`
	PaymentType      AccountActivityGetTransactionResponsePaymentType `json:"payment_type"`
	// Pending amount in cents
	PendingAmount int64 `json:"pending_amount"`
	// This field can have the runtime type of [TransactionPos].
	Pos interface{} `json:"pos"`
	// This field can have the runtime type of [PaymentRelatedAccountTokens].
	RelatedAccountTokens interface{} `json:"related_account_tokens"`
	// Transaction result
	Result AccountActivityGetTransactionResponseResult `json:"result"`
	// Settled amount in cents
	SettledAmount int64 `json:"settled_amount"`
	// Transaction source
	Source AccountActivityGetTransactionResponseSource `json:"source"`
	// Globally unique identifier for the financial account or card that will receive
	// the funds. Accepted type dependent on the program's use case
	ToFinancialAccountToken string    `json:"to_financial_account_token" format:"uuid"`
	TokenInfo               TokenInfo `json:"token_info,nullable"`
	// This field can have the runtime type of [BookTransferResponseTransactionSeries],
	// [ManagementOperationTransactionTransactionSeries].
	TransactionSeries interface{}                               `json:"transaction_series"`
	Type              AccountActivityGetTransactionResponseType `json:"type"`
	// User-defined identifier
	UserDefinedID string                                    `json:"user_defined_id,nullable"`
	JSON          accountActivityGetTransactionResponseJSON `json:"-"`
	// contains filtered or unexported fields
}

Response containing multiple transaction types. The `family` field determines which transaction type is returned: INTERNAL returns FinancialTransaction, TRANSFER returns BookTransferTransaction, CARD returns CardTransaction, PAYMENT returns PaymentTransaction, EXTERNAL_PAYMENT returns ExternalPaymentResponse, and MANAGEMENT_OPERATION returns ManagementOperationTransaction

func (AccountActivityGetTransactionResponse) AsUnion added in v0.87.0

AsUnion returns a AccountActivityGetTransactionResponseUnion interface which you can cast to the specific types for more type safety.

Possible runtime types of the union are AccountActivityGetTransactionResponseFinancialTransaction, BookTransferResponse, AccountActivityGetTransactionResponseCardTransaction, Payment, ExternalPayment, ManagementOperationTransaction.

func (*AccountActivityGetTransactionResponse) UnmarshalJSON added in v0.87.0

func (r *AccountActivityGetTransactionResponse) UnmarshalJSON(data []byte) (err error)

type AccountActivityGetTransactionResponseCardTransaction added in v0.87.0

type AccountActivityGetTransactionResponseCardTransaction struct {
	// Unique identifier for the transaction
	Token string `json:"token,required" format:"uuid"`
	// ISO 8601 timestamp of when the transaction was created
	Created time.Time `json:"created,required" format:"date-time"`
	// CARD - Card Transaction
	Family AccountActivityGetTransactionResponseCardTransactionFamily `json:"family,required"`
	// The status of the transaction
	Status AccountActivityGetTransactionResponseCardTransactionStatus `json:"status,required"`
	// ISO 8601 timestamp of when the transaction was last updated
	Updated time.Time                                                `json:"updated,required" format:"date-time"`
	JSON    accountActivityGetTransactionResponseCardTransactionJSON `json:"-"`
	Transaction
}

Card transaction with ledger base properties

func (*AccountActivityGetTransactionResponseCardTransaction) UnmarshalJSON added in v0.87.0

func (r *AccountActivityGetTransactionResponseCardTransaction) UnmarshalJSON(data []byte) (err error)

type AccountActivityGetTransactionResponseCardTransactionFamily added in v0.87.0

type AccountActivityGetTransactionResponseCardTransactionFamily string

CARD - Card Transaction

const (
	AccountActivityGetTransactionResponseCardTransactionFamilyCard AccountActivityGetTransactionResponseCardTransactionFamily = "CARD"
)

func (AccountActivityGetTransactionResponseCardTransactionFamily) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseCardTransactionStatus added in v0.87.0

type AccountActivityGetTransactionResponseCardTransactionStatus string

The status of the transaction

const (
	AccountActivityGetTransactionResponseCardTransactionStatusPending  AccountActivityGetTransactionResponseCardTransactionStatus = "PENDING"
	AccountActivityGetTransactionResponseCardTransactionStatusSettled  AccountActivityGetTransactionResponseCardTransactionStatus = "SETTLED"
	AccountActivityGetTransactionResponseCardTransactionStatusDeclined AccountActivityGetTransactionResponseCardTransactionStatus = "DECLINED"
	AccountActivityGetTransactionResponseCardTransactionStatusReversed AccountActivityGetTransactionResponseCardTransactionStatus = "REVERSED"
	AccountActivityGetTransactionResponseCardTransactionStatusCanceled AccountActivityGetTransactionResponseCardTransactionStatus = "CANCELED"
	AccountActivityGetTransactionResponseCardTransactionStatusReturned AccountActivityGetTransactionResponseCardTransactionStatus = "RETURNED"
)

func (AccountActivityGetTransactionResponseCardTransactionStatus) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseCategory added in v0.87.0

type AccountActivityGetTransactionResponseCategory string

Transaction category

const (
	AccountActivityGetTransactionResponseCategoryACH                    AccountActivityGetTransactionResponseCategory = "ACH"
	AccountActivityGetTransactionResponseCategoryBalanceOrFunding       AccountActivityGetTransactionResponseCategory = "BALANCE_OR_FUNDING"
	AccountActivityGetTransactionResponseCategoryFee                    AccountActivityGetTransactionResponseCategory = "FEE"
	AccountActivityGetTransactionResponseCategoryReward                 AccountActivityGetTransactionResponseCategory = "REWARD"
	AccountActivityGetTransactionResponseCategoryAdjustment             AccountActivityGetTransactionResponseCategory = "ADJUSTMENT"
	AccountActivityGetTransactionResponseCategoryDerecognition          AccountActivityGetTransactionResponseCategory = "DERECOGNITION"
	AccountActivityGetTransactionResponseCategoryDispute                AccountActivityGetTransactionResponseCategory = "DISPUTE"
	AccountActivityGetTransactionResponseCategoryCard                   AccountActivityGetTransactionResponseCategory = "CARD"
	AccountActivityGetTransactionResponseCategoryExternalACH            AccountActivityGetTransactionResponseCategory = "EXTERNAL_ACH"
	AccountActivityGetTransactionResponseCategoryExternalCheck          AccountActivityGetTransactionResponseCategory = "EXTERNAL_CHECK"
	AccountActivityGetTransactionResponseCategoryExternalFednow         AccountActivityGetTransactionResponseCategory = "EXTERNAL_FEDNOW"
	AccountActivityGetTransactionResponseCategoryExternalRtp            AccountActivityGetTransactionResponseCategory = "EXTERNAL_RTP"
	AccountActivityGetTransactionResponseCategoryExternalTransfer       AccountActivityGetTransactionResponseCategory = "EXTERNAL_TRANSFER"
	AccountActivityGetTransactionResponseCategoryExternalWire           AccountActivityGetTransactionResponseCategory = "EXTERNAL_WIRE"
	AccountActivityGetTransactionResponseCategoryManagementAdjustment   AccountActivityGetTransactionResponseCategory = "MANAGEMENT_ADJUSTMENT"
	AccountActivityGetTransactionResponseCategoryManagementDispute      AccountActivityGetTransactionResponseCategory = "MANAGEMENT_DISPUTE"
	AccountActivityGetTransactionResponseCategoryManagementFee          AccountActivityGetTransactionResponseCategory = "MANAGEMENT_FEE"
	AccountActivityGetTransactionResponseCategoryManagementReward       AccountActivityGetTransactionResponseCategory = "MANAGEMENT_REWARD"
	AccountActivityGetTransactionResponseCategoryManagementDisbursement AccountActivityGetTransactionResponseCategory = "MANAGEMENT_DISBURSEMENT"
	AccountActivityGetTransactionResponseCategoryProgramFunding         AccountActivityGetTransactionResponseCategory = "PROGRAM_FUNDING"
	AccountActivityGetTransactionResponseCategoryInternal               AccountActivityGetTransactionResponseCategory = "INTERNAL"
	AccountActivityGetTransactionResponseCategoryTransfer               AccountActivityGetTransactionResponseCategory = "TRANSFER"
)

func (AccountActivityGetTransactionResponseCategory) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseDirection added in v0.87.0

type AccountActivityGetTransactionResponseDirection string

Transfer direction

const (
	AccountActivityGetTransactionResponseDirectionCredit AccountActivityGetTransactionResponseDirection = "CREDIT"
	AccountActivityGetTransactionResponseDirectionDebit  AccountActivityGetTransactionResponseDirection = "DEBIT"
)

func (AccountActivityGetTransactionResponseDirection) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseFamily added in v0.87.0

type AccountActivityGetTransactionResponseFamily string

INTERNAL - Financial Transaction

const (
	AccountActivityGetTransactionResponseFamilyInternal            AccountActivityGetTransactionResponseFamily = "INTERNAL"
	AccountActivityGetTransactionResponseFamilyTransfer            AccountActivityGetTransactionResponseFamily = "TRANSFER"
	AccountActivityGetTransactionResponseFamilyCard                AccountActivityGetTransactionResponseFamily = "CARD"
	AccountActivityGetTransactionResponseFamilyPayment             AccountActivityGetTransactionResponseFamily = "PAYMENT"
	AccountActivityGetTransactionResponseFamilyExternalPayment     AccountActivityGetTransactionResponseFamily = "EXTERNAL_PAYMENT"
	AccountActivityGetTransactionResponseFamilyManagementOperation AccountActivityGetTransactionResponseFamily = "MANAGEMENT_OPERATION"
)

func (AccountActivityGetTransactionResponseFamily) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseFinancialTransaction added in v0.87.0

type AccountActivityGetTransactionResponseFinancialTransaction struct {
	// Unique identifier for the transaction
	Token string `json:"token,required" format:"uuid"`
	// Transaction category
	Category AccountActivityGetTransactionResponseFinancialTransactionCategory `json:"category,required"`
	// ISO 8601 timestamp of when the transaction was created
	Created time.Time `json:"created,required" format:"date-time"`
	// Currency of the transaction, represented in ISO 4217 format
	Currency string `json:"currency,required"`
	// Transaction descriptor
	Descriptor string `json:"descriptor,required"`
	// List of transaction events
	Events []shared.FinancialEvent `json:"events,required"`
	// INTERNAL - Financial Transaction
	Family AccountActivityGetTransactionResponseFinancialTransactionFamily `json:"family,required"`
	// Financial account token associated with the transaction
	FinancialAccountToken string `json:"financial_account_token,required" format:"uuid"`
	// Pending amount in cents
	PendingAmount int64 `json:"pending_amount,required"`
	// Transaction result
	Result AccountActivityGetTransactionResponseFinancialTransactionResult `json:"result,required"`
	// Settled amount in cents
	SettledAmount int64 `json:"settled_amount,required"`
	// The status of the transaction
	Status AccountActivityGetTransactionResponseFinancialTransactionStatus `json:"status,required"`
	// ISO 8601 timestamp of when the transaction was last updated
	Updated time.Time                                                     `json:"updated,required" format:"date-time"`
	JSON    accountActivityGetTransactionResponseFinancialTransactionJSON `json:"-"`
}

Financial transaction with inheritance from unified base transaction

func (*AccountActivityGetTransactionResponseFinancialTransaction) UnmarshalJSON added in v0.87.0

type AccountActivityGetTransactionResponseFinancialTransactionCategory added in v0.87.0

type AccountActivityGetTransactionResponseFinancialTransactionCategory string

Transaction category

const (
	AccountActivityGetTransactionResponseFinancialTransactionCategoryACH                    AccountActivityGetTransactionResponseFinancialTransactionCategory = "ACH"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryBalanceOrFunding       AccountActivityGetTransactionResponseFinancialTransactionCategory = "BALANCE_OR_FUNDING"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryFee                    AccountActivityGetTransactionResponseFinancialTransactionCategory = "FEE"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryReward                 AccountActivityGetTransactionResponseFinancialTransactionCategory = "REWARD"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryAdjustment             AccountActivityGetTransactionResponseFinancialTransactionCategory = "ADJUSTMENT"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryDerecognition          AccountActivityGetTransactionResponseFinancialTransactionCategory = "DERECOGNITION"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryDispute                AccountActivityGetTransactionResponseFinancialTransactionCategory = "DISPUTE"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryCard                   AccountActivityGetTransactionResponseFinancialTransactionCategory = "CARD"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryExternalACH            AccountActivityGetTransactionResponseFinancialTransactionCategory = "EXTERNAL_ACH"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryExternalCheck          AccountActivityGetTransactionResponseFinancialTransactionCategory = "EXTERNAL_CHECK"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryExternalFednow         AccountActivityGetTransactionResponseFinancialTransactionCategory = "EXTERNAL_FEDNOW"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryExternalRtp            AccountActivityGetTransactionResponseFinancialTransactionCategory = "EXTERNAL_RTP"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryExternalTransfer       AccountActivityGetTransactionResponseFinancialTransactionCategory = "EXTERNAL_TRANSFER"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryExternalWire           AccountActivityGetTransactionResponseFinancialTransactionCategory = "EXTERNAL_WIRE"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryManagementAdjustment   AccountActivityGetTransactionResponseFinancialTransactionCategory = "MANAGEMENT_ADJUSTMENT"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryManagementDispute      AccountActivityGetTransactionResponseFinancialTransactionCategory = "MANAGEMENT_DISPUTE"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryManagementFee          AccountActivityGetTransactionResponseFinancialTransactionCategory = "MANAGEMENT_FEE"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryManagementReward       AccountActivityGetTransactionResponseFinancialTransactionCategory = "MANAGEMENT_REWARD"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryManagementDisbursement AccountActivityGetTransactionResponseFinancialTransactionCategory = "MANAGEMENT_DISBURSEMENT"
	AccountActivityGetTransactionResponseFinancialTransactionCategoryProgramFunding         AccountActivityGetTransactionResponseFinancialTransactionCategory = "PROGRAM_FUNDING"
)

func (AccountActivityGetTransactionResponseFinancialTransactionCategory) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseFinancialTransactionFamily added in v0.87.0

type AccountActivityGetTransactionResponseFinancialTransactionFamily string

INTERNAL - Financial Transaction

const (
	AccountActivityGetTransactionResponseFinancialTransactionFamilyInternal AccountActivityGetTransactionResponseFinancialTransactionFamily = "INTERNAL"
)

func (AccountActivityGetTransactionResponseFinancialTransactionFamily) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseFinancialTransactionResult added in v0.87.0

type AccountActivityGetTransactionResponseFinancialTransactionResult string

Transaction result

const (
	AccountActivityGetTransactionResponseFinancialTransactionResultApproved AccountActivityGetTransactionResponseFinancialTransactionResult = "APPROVED"
	AccountActivityGetTransactionResponseFinancialTransactionResultDeclined AccountActivityGetTransactionResponseFinancialTransactionResult = "DECLINED"
)

func (AccountActivityGetTransactionResponseFinancialTransactionResult) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseFinancialTransactionStatus added in v0.87.0

type AccountActivityGetTransactionResponseFinancialTransactionStatus string

The status of the transaction

const (
	AccountActivityGetTransactionResponseFinancialTransactionStatusPending  AccountActivityGetTransactionResponseFinancialTransactionStatus = "PENDING"
	AccountActivityGetTransactionResponseFinancialTransactionStatusSettled  AccountActivityGetTransactionResponseFinancialTransactionStatus = "SETTLED"
	AccountActivityGetTransactionResponseFinancialTransactionStatusDeclined AccountActivityGetTransactionResponseFinancialTransactionStatus = "DECLINED"
	AccountActivityGetTransactionResponseFinancialTransactionStatusReversed AccountActivityGetTransactionResponseFinancialTransactionStatus = "REVERSED"
	AccountActivityGetTransactionResponseFinancialTransactionStatusCanceled AccountActivityGetTransactionResponseFinancialTransactionStatus = "CANCELED"
	AccountActivityGetTransactionResponseFinancialTransactionStatusReturned AccountActivityGetTransactionResponseFinancialTransactionStatus = "RETURNED"
)

func (AccountActivityGetTransactionResponseFinancialTransactionStatus) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseMethod added in v0.87.0

type AccountActivityGetTransactionResponseMethod string

Transfer method

const (
	AccountActivityGetTransactionResponseMethodACHNextDay AccountActivityGetTransactionResponseMethod = "ACH_NEXT_DAY"
	AccountActivityGetTransactionResponseMethodACHSameDay AccountActivityGetTransactionResponseMethod = "ACH_SAME_DAY"
	AccountActivityGetTransactionResponseMethodWire       AccountActivityGetTransactionResponseMethod = "WIRE"
)

func (AccountActivityGetTransactionResponseMethod) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseNetwork added in v0.87.0

type AccountActivityGetTransactionResponseNetwork string

Card network of the authorization. Value is `UNKNOWN` when Lithic cannot determine the network code from the upstream provider.

const (
	AccountActivityGetTransactionResponseNetworkAmex       AccountActivityGetTransactionResponseNetwork = "AMEX"
	AccountActivityGetTransactionResponseNetworkInterlink  AccountActivityGetTransactionResponseNetwork = "INTERLINK"
	AccountActivityGetTransactionResponseNetworkMaestro    AccountActivityGetTransactionResponseNetwork = "MAESTRO"
	AccountActivityGetTransactionResponseNetworkMastercard AccountActivityGetTransactionResponseNetwork = "MASTERCARD"
	AccountActivityGetTransactionResponseNetworkUnknown    AccountActivityGetTransactionResponseNetwork = "UNKNOWN"
	AccountActivityGetTransactionResponseNetworkVisa       AccountActivityGetTransactionResponseNetwork = "VISA"
)

func (AccountActivityGetTransactionResponseNetwork) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponsePaymentType added in v0.87.0

type AccountActivityGetTransactionResponsePaymentType string
const (
	AccountActivityGetTransactionResponsePaymentTypeDeposit    AccountActivityGetTransactionResponsePaymentType = "DEPOSIT"
	AccountActivityGetTransactionResponsePaymentTypeWithdrawal AccountActivityGetTransactionResponsePaymentType = "WITHDRAWAL"
)

func (AccountActivityGetTransactionResponsePaymentType) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseResult added in v0.87.0

type AccountActivityGetTransactionResponseResult string

Transaction result

const (
	AccountActivityGetTransactionResponseResultApproved                    AccountActivityGetTransactionResponseResult = "APPROVED"
	AccountActivityGetTransactionResponseResultDeclined                    AccountActivityGetTransactionResponseResult = "DECLINED"
	AccountActivityGetTransactionResponseResultAccountPaused               AccountActivityGetTransactionResponseResult = "ACCOUNT_PAUSED"
	AccountActivityGetTransactionResponseResultAccountStateTransactionFail AccountActivityGetTransactionResponseResult = "ACCOUNT_STATE_TRANSACTION_FAIL"
	AccountActivityGetTransactionResponseResultBankConnectionError         AccountActivityGetTransactionResponseResult = "BANK_CONNECTION_ERROR"
	AccountActivityGetTransactionResponseResultBankNotVerified             AccountActivityGetTransactionResponseResult = "BANK_NOT_VERIFIED"
	AccountActivityGetTransactionResponseResultCardClosed                  AccountActivityGetTransactionResponseResult = "CARD_CLOSED"
	AccountActivityGetTransactionResponseResultCardPaused                  AccountActivityGetTransactionResponseResult = "CARD_PAUSED"
	AccountActivityGetTransactionResponseResultFraudAdvice                 AccountActivityGetTransactionResponseResult = "FRAUD_ADVICE"
	AccountActivityGetTransactionResponseResultIgnoredTtlExpiry            AccountActivityGetTransactionResponseResult = "IGNORED_TTL_EXPIRY"
	AccountActivityGetTransactionResponseResultSuspectedFraud              AccountActivityGetTransactionResponseResult = "SUSPECTED_FRAUD"
	AccountActivityGetTransactionResponseResultInactiveAccount             AccountActivityGetTransactionResponseResult = "INACTIVE_ACCOUNT"
	AccountActivityGetTransactionResponseResultIncorrectPin                AccountActivityGetTransactionResponseResult = "INCORRECT_PIN"
	AccountActivityGetTransactionResponseResultInvalidCardDetails          AccountActivityGetTransactionResponseResult = "INVALID_CARD_DETAILS"
	AccountActivityGetTransactionResponseResultInsufficientFunds           AccountActivityGetTransactionResponseResult = "INSUFFICIENT_FUNDS"
	AccountActivityGetTransactionResponseResultInsufficientFundsPreload    AccountActivityGetTransactionResponseResult = "INSUFFICIENT_FUNDS_PRELOAD"
	AccountActivityGetTransactionResponseResultInvalidTransaction          AccountActivityGetTransactionResponseResult = "INVALID_TRANSACTION"
	AccountActivityGetTransactionResponseResultMerchantBlacklist           AccountActivityGetTransactionResponseResult = "MERCHANT_BLACKLIST"
	AccountActivityGetTransactionResponseResultOriginalNotFound            AccountActivityGetTransactionResponseResult = "ORIGINAL_NOT_FOUND"
	AccountActivityGetTransactionResponseResultPreviouslyCompleted         AccountActivityGetTransactionResponseResult = "PREVIOUSLY_COMPLETED"
	AccountActivityGetTransactionResponseResultSingleUseRecharged          AccountActivityGetTransactionResponseResult = "SINGLE_USE_RECHARGED"
	AccountActivityGetTransactionResponseResultSwitchInoperativeAdvice     AccountActivityGetTransactionResponseResult = "SWITCH_INOPERATIVE_ADVICE"
	AccountActivityGetTransactionResponseResultUnauthorizedMerchant        AccountActivityGetTransactionResponseResult = "UNAUTHORIZED_MERCHANT"
	AccountActivityGetTransactionResponseResultUnknownHostTimeout          AccountActivityGetTransactionResponseResult = "UNKNOWN_HOST_TIMEOUT"
	AccountActivityGetTransactionResponseResultUserTransactionLimit        AccountActivityGetTransactionResponseResult = "USER_TRANSACTION_LIMIT"
)

func (AccountActivityGetTransactionResponseResult) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseSource added in v0.87.0

type AccountActivityGetTransactionResponseSource string

Transaction source

const (
	AccountActivityGetTransactionResponseSourceLithic   AccountActivityGetTransactionResponseSource = "LITHIC"
	AccountActivityGetTransactionResponseSourceExternal AccountActivityGetTransactionResponseSource = "EXTERNAL"
	AccountActivityGetTransactionResponseSourceCustomer AccountActivityGetTransactionResponseSource = "CUSTOMER"
)

func (AccountActivityGetTransactionResponseSource) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseStatus added in v0.87.0

type AccountActivityGetTransactionResponseStatus string

The status of the transaction

const (
	AccountActivityGetTransactionResponseStatusPending  AccountActivityGetTransactionResponseStatus = "PENDING"
	AccountActivityGetTransactionResponseStatusSettled  AccountActivityGetTransactionResponseStatus = "SETTLED"
	AccountActivityGetTransactionResponseStatusDeclined AccountActivityGetTransactionResponseStatus = "DECLINED"
	AccountActivityGetTransactionResponseStatusReversed AccountActivityGetTransactionResponseStatus = "REVERSED"
	AccountActivityGetTransactionResponseStatusCanceled AccountActivityGetTransactionResponseStatus = "CANCELED"
	AccountActivityGetTransactionResponseStatusReturned AccountActivityGetTransactionResponseStatus = "RETURNED"
	AccountActivityGetTransactionResponseStatusExpired  AccountActivityGetTransactionResponseStatus = "EXPIRED"
	AccountActivityGetTransactionResponseStatusVoided   AccountActivityGetTransactionResponseStatus = "VOIDED"
)

func (AccountActivityGetTransactionResponseStatus) IsKnown added in v0.87.0

type AccountActivityGetTransactionResponseType added in v0.90.0

type AccountActivityGetTransactionResponseType string
const (
	AccountActivityGetTransactionResponseTypeOriginationCredit   AccountActivityGetTransactionResponseType = "ORIGINATION_CREDIT"
	AccountActivityGetTransactionResponseTypeOriginationDebit    AccountActivityGetTransactionResponseType = "ORIGINATION_DEBIT"
	AccountActivityGetTransactionResponseTypeReceiptCredit       AccountActivityGetTransactionResponseType = "RECEIPT_CREDIT"
	AccountActivityGetTransactionResponseTypeReceiptDebit        AccountActivityGetTransactionResponseType = "RECEIPT_DEBIT"
	AccountActivityGetTransactionResponseTypeWireInboundPayment  AccountActivityGetTransactionResponseType = "WIRE_INBOUND_PAYMENT"
	AccountActivityGetTransactionResponseTypeWireInboundAdmin    AccountActivityGetTransactionResponseType = "WIRE_INBOUND_ADMIN"
	AccountActivityGetTransactionResponseTypeWireOutboundPayment AccountActivityGetTransactionResponseType = "WIRE_OUTBOUND_PAYMENT"
	AccountActivityGetTransactionResponseTypeWireOutboundAdmin   AccountActivityGetTransactionResponseType = "WIRE_OUTBOUND_ADMIN"
)

func (AccountActivityGetTransactionResponseType) IsKnown added in v0.90.0

type AccountActivityGetTransactionResponseUnion added in v0.87.0

type AccountActivityGetTransactionResponseUnion interface {
	// contains filtered or unexported methods
}

Response containing multiple transaction types. The `family` field determines which transaction type is returned: INTERNAL returns FinancialTransaction, TRANSFER returns BookTransferTransaction, CARD returns CardTransaction, PAYMENT returns PaymentTransaction, EXTERNAL_PAYMENT returns ExternalPaymentResponse, and MANAGEMENT_OPERATION returns ManagementOperationTransaction

Union satisfied by AccountActivityGetTransactionResponseFinancialTransaction, BookTransferResponse, AccountActivityGetTransactionResponseCardTransaction, Payment, ExternalPayment or ManagementOperationTransaction.

type AccountActivityListParams added in v0.87.0

type AccountActivityListParams struct {
	// Filter by account token
	AccountToken param.Field[string] `query:"account_token" format:"uuid"`
	// Date string in RFC 3339 format. Only entries created after the specified time
	// will be included. UTC time zone.
	Begin param.Field[time.Time] `query:"begin" format:"date-time"`
	// Filter by business account token
	BusinessAccountToken param.Field[string] `query:"business_account_token" format:"uuid"`
	// Filter by transaction category
	Category param.Field[AccountActivityListParamsCategory] `query:"category"`
	// Date string in RFC 3339 format. Only entries created before the specified time
	// will be included. UTC time zone.
	End param.Field[time.Time] `query:"end" format:"date-time"`
	// A cursor representing an item's token before which a page of results should end.
	// Used to retrieve the previous page of results before this item.
	EndingBefore param.Field[string] `query:"ending_before"`
	// Filter by financial account token
	FinancialAccountToken param.Field[string] `query:"financial_account_token" format:"uuid"`
	// Page size (for pagination).
	PageSize param.Field[int64] `query:"page_size"`
	// Filter by transaction result
	Result param.Field[AccountActivityListParamsResult] `query:"result"`
	// A cursor representing an item's token after which a page of results should
	// begin. Used to retrieve the next page of results after this item.
	StartingAfter param.Field[string] `query:"starting_after"`
	// Filter by transaction status
	Status param.Field[AccountActivityListParamsStatus] `query:"status"`
}

func (AccountActivityListParams) URLQuery added in v0.87.0

func (r AccountActivityListParams) URLQuery() (v url.Values)

URLQuery serializes AccountActivityListParams's query parameters as `url.Values`.

type AccountActivityListParamsCategory added in v0.87.0

type AccountActivityListParamsCategory string

Filter by transaction category

const (
	AccountActivityListParamsCategoryACH                    AccountActivityListParamsCategory = "ACH"
	AccountActivityListParamsCategoryBalanceOrFunding       AccountActivityListParamsCategory = "BALANCE_OR_FUNDING"
	AccountActivityListParamsCategoryFee                    AccountActivityListParamsCategory = "FEE"
	AccountActivityListParamsCategoryReward                 AccountActivityListParamsCategory = "REWARD"
	AccountActivityListParamsCategoryAdjustment             AccountActivityListParamsCategory = "ADJUSTMENT"
	AccountActivityListParamsCategoryDerecognition          AccountActivityListParamsCategory = "DERECOGNITION"
	AccountActivityListParamsCategoryDispute                AccountActivityListParamsCategory = "DISPUTE"
	AccountActivityListParamsCategoryCard                   AccountActivityListParamsCategory = "CARD"
	AccountActivityListParamsCategoryExternalACH            AccountActivityListParamsCategory = "EXTERNAL_ACH"
	AccountActivityListParamsCategoryExternalCheck          AccountActivityListParamsCategory = "EXTERNAL_CHECK"
	AccountActivityListParamsCategoryExternalFednow         AccountActivityListParamsCategory = "EXTERNAL_FEDNOW"
	AccountActivityListParamsCategoryExternalRtp            AccountActivityListParamsCategory = "EXTERNAL_RTP"
	AccountActivityListParamsCategoryExternalTransfer       AccountActivityListParamsCategory = "EXTERNAL_TRANSFER"
	AccountActivityListParamsCategoryExternalWire           AccountActivityListParamsCategory = "EXTERNAL_WIRE"
	AccountActivityListParamsCategoryManagementAdjustment   AccountActivityListParamsCategory = "MANAGEMENT_ADJUSTMENT"
	AccountActivityListParamsCategoryManagementDispute      AccountActivityListParamsCategory = "MANAGEMENT_DISPUTE"
	AccountActivityListParamsCategoryManagementFee          AccountActivityListParamsCategory = "MANAGEMENT_FEE"
	AccountActivityListParamsCategoryManagementReward       AccountActivityListParamsCategory = "MANAGEMENT_REWARD"
	AccountActivityListParamsCategoryManagementDisbursement AccountActivityListParamsCategory = "MANAGEMENT_DISBURSEMENT"
	AccountActivityListParamsCategoryProgramFunding         AccountActivityListParamsCategory = "PROGRAM_FUNDING"
)

func (AccountActivityListParamsCategory) IsKnown added in v0.87.0

type AccountActivityListParamsResult added in v0.87.0

type AccountActivityListParamsResult string

Filter by transaction result

const (
	AccountActivityListParamsResultApproved AccountActivityListParamsResult = "APPROVED"
	AccountActivityListParamsResultDeclined AccountActivityListParamsResult = "DECLINED"
)

func (AccountActivityListParamsResult) IsKnown added in v0.87.0

type AccountActivityListParamsStatus added in v0.87.0

type AccountActivityListParamsStatus string

Filter by transaction status

const (
	AccountActivityListParamsStatusDeclined AccountActivityListParamsStatus = "DECLINED"
	AccountActivityListParamsStatusExpired  AccountActivityListParamsStatus = "EXPIRED"
	AccountActivityListParamsStatusPending  AccountActivityListParamsStatus = "PENDING"
	AccountActivityListParamsStatusReturned AccountActivityListParamsStatus = "RETURNED"
	AccountActivityListParamsStatusReversed AccountActivityListParamsStatus = "REVERSED"
	AccountActivityListParamsStatusSettled  AccountActivityListParamsStatus = "SETTLED"
	AccountActivityListParamsStatusVoided   AccountActivityListParamsStatus = "VOIDED"
)

func (AccountActivityListParamsStatus) IsKnown added in v0.87.0

type AccountActivityListResponse added in v0.87.0

type AccountActivityListResponse struct {
	// Unique identifier for the transaction
	Token string `json:"token,required" format:"uuid"`
	// ISO 8601 timestamp of when the transaction was created
	Created time.Time `json:"created,required" format:"date-time"`
	// The status of the transaction
	Status AccountActivityListResponseStatus `json:"status,required"`
	// ISO 8601 timestamp of when the transaction was last updated
	Updated time.Time `json:"updated,required" format:"date-time"`
	// The token for the account associated with this transaction.
	AccountToken string `json:"account_token" format:"uuid"`
	// Fee assessed by the merchant and paid for by the cardholder in the smallest unit
	// of the currency. Will be zero if no fee is assessed. Rebates may be transmitted
	// as a negative value to indicate credited fees.
	AcquirerFee int64 `json:"acquirer_fee,nullable"`
	// Unique identifier assigned to a transaction by the acquirer that can be used in
	// dispute and chargeback filing. This field has been deprecated in favor of the
	// `acquirer_reference_number` that resides in the event-level `network_info`.
	//
	// Deprecated: deprecated
	AcquirerReferenceNumber string `json:"acquirer_reference_number,nullable"`
	// When the transaction is pending, this represents the authorization amount of the
	// transaction in the anticipated settlement currency. Once the transaction has
	// settled, this field represents the settled amount in the settlement currency.
	//
	// Deprecated: deprecated
	Amount int64 `json:"amount"`
	// This field can have the runtime type of [TransactionAmounts].
	Amounts interface{} `json:"amounts"`
	// The authorization amount of the transaction in the anticipated settlement
	// currency.
	//
	// Deprecated: deprecated
	AuthorizationAmount int64 `json:"authorization_amount,nullable"`
	// A fixed-width 6-digit numeric identifier that can be used to identify a
	// transaction with networks.
	AuthorizationCode string `json:"authorization_code,nullable"`
	// This field can have the runtime type of [TransactionAvs].
	Avs interface{} `json:"avs"`
	// Token for the card used in this transaction.
	CardToken                string                   `json:"card_token" format:"uuid"`
	CardholderAuthentication CardholderAuthentication `json:"cardholder_authentication,nullable"`
	// Transaction category
	Category AccountActivityListResponseCategory `json:"category"`
	// Currency of the transaction, represented in ISO 4217 format
	Currency string `json:"currency"`
	// Transaction descriptor
	Descriptor string `json:"descriptor"`
	// Transfer direction
	Direction AccountActivityListResponseDirection `json:"direction"`
	// This field can have the runtime type of [[]shared.FinancialEvent],
	// [[]BookTransferResponseEvent], [[]TransactionEvent], [[]PaymentEvent],
	// [[]ExternalPaymentEvent], [[]ManagementOperationTransactionEvent].
	Events interface{} `json:"events"`
	// Expected release date for the transaction
	ExpectedReleaseDate time.Time `json:"expected_release_date,nullable" format:"date"`
	// External bank account token
	ExternalBankAccountToken string `json:"external_bank_account_token,nullable" format:"uuid"`
	// External ID defined by the customer
	ExternalID string `json:"external_id,nullable"`
	// External resource associated with the management operation
	ExternalResource ExternalResource `json:"external_resource,nullable"`
	// INTERNAL - Financial Transaction
	Family AccountActivityListResponseFamily `json:"family"`
	// Financial account token associated with the transaction
	FinancialAccountToken string `json:"financial_account_token,nullable" format:"uuid"`
	// Globally unique identifier for the financial account or card that will send the
	// funds. Accepted type dependent on the program's use case
	FromFinancialAccountToken string          `json:"from_financial_account_token" format:"uuid"`
	Merchant                  shared.Merchant `json:"merchant"`
	// Analogous to the 'amount', but in the merchant currency.
	//
	// Deprecated: deprecated
	MerchantAmount int64 `json:"merchant_amount,nullable"`
	// Analogous to the 'authorization_amount', but in the merchant currency.
	//
	// Deprecated: deprecated
	MerchantAuthorizationAmount int64 `json:"merchant_authorization_amount,nullable"`
	// 3-character alphabetic ISO 4217 code for the local currency of the transaction.
	//
	// Deprecated: deprecated
	MerchantCurrency string `json:"merchant_currency"`
	// Transfer method
	Method AccountActivityListResponseMethod `json:"method"`
	// This field can have the runtime type of [PaymentMethodAttributes].
	MethodAttributes interface{} `json:"method_attributes"`
	// Card network of the authorization. Value is `UNKNOWN` when Lithic cannot
	// determine the network code from the upstream provider.
	Network AccountActivityListResponseNetwork `json:"network,nullable"`
	// Network-provided score assessing risk level associated with a given
	// authorization. Scores are on a range of 0-999, with 0 representing the lowest
	// risk and 999 representing the highest risk. For Visa transactions, where the raw
	// score has a range of 0-99, Lithic will normalize the score by multiplying the
	// raw score by 10x.
	NetworkRiskScore int64                                  `json:"network_risk_score,nullable"`
	PaymentType      AccountActivityListResponsePaymentType `json:"payment_type"`
	// Pending amount in cents
	PendingAmount int64 `json:"pending_amount"`
	// This field can have the runtime type of [TransactionPos].
	Pos interface{} `json:"pos"`
	// This field can have the runtime type of [PaymentRelatedAccountTokens].
	RelatedAccountTokens interface{} `json:"related_account_tokens"`
	// Transaction result
	Result AccountActivityListResponseResult `json:"result"`
	// Settled amount in cents
	SettledAmount int64 `json:"settled_amount"`
	// Transaction source
	Source AccountActivityListResponseSource `json:"source"`
	// Globally unique identifier for the financial account or card that will receive
	// the funds. Accepted type dependent on the program's use case
	ToFinancialAccountToken string    `json:"to_financial_account_token" format:"uuid"`
	TokenInfo               TokenInfo `json:"token_info,nullable"`
	// This field can have the runtime type of [BookTransferResponseTransactionSeries],
	// [ManagementOperationTransactionTransactionSeries].
	TransactionSeries interface{}                     `json:"transaction_series"`
	Type              AccountActivityListResponseType `json:"type"`
	// User-defined identifier
	UserDefinedID string                          `json:"user_defined_id,nullable"`
	JSON          accountActivityListResponseJSON `json:"-"`
	// contains filtered or unexported fields
}

Response containing multiple transaction types. The `family` field determines which transaction type is returned: INTERNAL returns FinancialTransaction, TRANSFER returns BookTransferTransaction, CARD returns CardTransaction, PAYMENT returns PaymentTransaction, EXTERNAL_PAYMENT returns ExternalPaymentResponse, and MANAGEMENT_OPERATION returns ManagementOperationTransaction

func (AccountActivityListResponse) AsUnion added in v0.87.0

AsUnion returns a AccountActivityListResponseUnion interface which you can cast to the specific types for more type safety.

Possible runtime types of the union are AccountActivityListResponseFinancialTransaction, BookTransferResponse, AccountActivityListResponseCardTransaction, Payment, ExternalPayment, ManagementOperationTransaction.

func (*AccountActivityListResponse) UnmarshalJSON added in v0.87.0

func (r *AccountActivityListResponse) UnmarshalJSON(data []byte) (err error)

type AccountActivityListResponseCardTransaction added in v0.87.0

type AccountActivityListResponseCardTransaction struct {
	// Unique identifier for the transaction
	Token string `json:"token,required" format:"uuid"`
	// ISO 8601 timestamp of when the transaction was created
	Created time.Time `json:"created,required" format:"date-time"`
	// CARD - Card Transaction
	Family AccountActivityListResponseCardTransactionFamily `json:"family,required"`
	// The status of the transaction
	Status AccountActivityListResponseCardTransactionStatus `json:"status,required"`
	// ISO 8601 timestamp of when the transaction was last updated
	Updated time.Time                                      `json:"updated,required" format:"date-time"`
	JSON    accountActivityListResponseCardTransactionJSON `json:"-"`
	Transaction
}

Card transaction with ledger base properties

func (*AccountActivityListResponseCardTransaction) UnmarshalJSON added in v0.87.0

func (r *AccountActivityListResponseCardTransaction) UnmarshalJSON(data []byte) (err error)

type AccountActivityListResponseCardTransactionFamily added in v0.87.0

type AccountActivityListResponseCardTransactionFamily string

CARD - Card Transaction

const (
	AccountActivityListResponseCardTransactionFamilyCard AccountActivityListResponseCardTransactionFamily = "CARD"
)

func (AccountActivityListResponseCardTransactionFamily) IsKnown added in v0.87.0

type AccountActivityListResponseCardTransactionStatus added in v0.87.0

type AccountActivityListResponseCardTransactionStatus string

The status of the transaction

const (
	AccountActivityListResponseCardTransactionStatusPending  AccountActivityListResponseCardTransactionStatus = "PENDING"
	AccountActivityListResponseCardTransactionStatusSettled  AccountActivityListResponseCardTransactionStatus = "SETTLED"
	AccountActivityListResponseCardTransactionStatusDeclined AccountActivityListResponseCardTransactionStatus = "DECLINED"
	AccountActivityListResponseCardTransactionStatusReversed AccountActivityListResponseCardTransactionStatus = "REVERSED"
	AccountActivityListResponseCardTransactionStatusCanceled AccountActivityListResponseCardTransactionStatus = "CANCELED"
	AccountActivityListResponseCardTransactionStatusReturned AccountActivityListResponseCardTransactionStatus = "RETURNED"
)

func (AccountActivityListResponseCardTransactionStatus) IsKnown added in v0.87.0

type AccountActivityListResponseCategory added in v0.87.0

type AccountActivityListResponseCategory string

Transaction category

const (
	AccountActivityListResponseCategoryACH                    AccountActivityListResponseCategory = "ACH"
	AccountActivityListResponseCategoryBalanceOrFunding       AccountActivityListResponseCategory = "BALANCE_OR_FUNDING"
	AccountActivityListResponseCategoryFee                    AccountActivityListResponseCategory = "FEE"
	AccountActivityListResponseCategoryReward                 AccountActivityListResponseCategory = "REWARD"
	AccountActivityListResponseCategoryAdjustment             AccountActivityListResponseCategory = "ADJUSTMENT"
	AccountActivityListResponseCategoryDerecognition          AccountActivityListResponseCategory = "DERECOGNITION"
	AccountActivityListResponseCategoryDispute                AccountActivityListResponseCategory = "DISPUTE"
	AccountActivityListResponseCategoryCard                   AccountActivityListResponseCategory = "CARD"
	AccountActivityListResponseCategoryExternalACH            AccountActivityListResponseCategory = "EXTERNAL_ACH"
	AccountActivityListResponseCategoryExternalCheck          AccountActivityListResponseCategory = "EXTERNAL_CHECK"
	AccountActivityListResponseCategoryExternalFednow         AccountActivityListResponseCategory = "EXTERNAL_FEDNOW"
	AccountActivityListResponseCategoryExternalRtp            AccountActivityListResponseCategory = "EXTERNAL_RTP"
	AccountActivityListResponseCategoryExternalTransfer       AccountActivityListResponseCategory = "EXTERNAL_TRANSFER"
	AccountActivityListResponseCategoryExternalWire           AccountActivityListResponseCategory = "EXTERNAL_WIRE"
	AccountActivityListResponseCategoryManagementAdjustment   AccountActivityListResponseCategory = "MANAGEMENT_ADJUSTMENT"
	AccountActivityListResponseCategoryManagementDispute      AccountActivityListResponseCategory = "MANAGEMENT_DISPUTE"
	AccountActivityListResponseCategoryManagementFee          AccountActivityListResponseCategory = "MANAGEMENT_FEE"
	AccountActivityListResponseCategoryManagementReward       AccountActivityListResponseCategory = "MANAGEMENT_REWARD"
	AccountActivityListResponseCategoryManagementDisbursement AccountActivityListResponseCategory = "MANAGEMENT_DISBURSEMENT"
	AccountActivityListResponseCategoryProgramFunding         AccountActivityListResponseCategory = "PROGRAM_FUNDING"
	AccountActivityListResponseCategoryInternal               AccountActivityListResponseCategory = "INTERNAL"
	AccountActivityListResponseCategoryTransfer               AccountActivityListResponseCategory = "TRANSFER"
)

func (AccountActivityListResponseCategory) IsKnown added in v0.87.0

type AccountActivityListResponseDirection added in v0.87.0

type AccountActivityListResponseDirection string

Transfer direction

const (
	AccountActivityListResponseDirectionCredit AccountActivityListResponseDirection = "CREDIT"
	AccountActivityListResponseDirectionDebit  AccountActivityListResponseDirection = "DEBIT"
)

func (AccountActivityListResponseDirection) IsKnown added in v0.87.0

type AccountActivityListResponseFamily added in v0.87.0

type AccountActivityListResponseFamily string

INTERNAL - Financial Transaction

const (
	AccountActivityListResponseFamilyInternal            AccountActivityListResponseFamily = "INTERNAL"
	AccountActivityListResponseFamilyTransfer            AccountActivityListResponseFamily = "TRANSFER"
	AccountActivityListResponseFamilyCard                AccountActivityListResponseFamily = "CARD"
	AccountActivityListResponseFamilyPayment             AccountActivityListResponseFamily = "PAYMENT"
	AccountActivityListResponseFamilyExternalPayment     AccountActivityListResponseFamily = "EXTERNAL_PAYMENT"
	AccountActivityListResponseFamilyManagementOperation AccountActivityListResponseFamily = "MANAGEMENT_OPERATION"
)

func (AccountActivityListResponseFamily) IsKnown added in v0.87.0

type AccountActivityListResponseFinancialTransaction added in v0.87.0

type AccountActivityListResponseFinancialTransaction struct {
	// Unique identifier for the transaction
	Token string `json:"token,required" format:"uuid"`
	// Transaction category
	Category AccountActivityListResponseFinancialTransactionCategory `json:"category,required"`
	// ISO 8601 timestamp of when the transaction was created
	Created time.Time `json:"created,required" format:"date-time"`
	// Currency of the transaction, represented in ISO 4217 format
	Currency string `json:"currency,required"`
	// Transaction descriptor
	Descriptor string `json:"descriptor,required"`
	// List of transaction events
	Events []shared.FinancialEvent `json:"events,required"`
	// INTERNAL - Financial Transaction
	Family AccountActivityListResponseFinancialTransactionFamily `json:"family,required"`
	// Financial account token associated with the transaction
	FinancialAccountToken string `json:"financial_account_token,required" format:"uuid"`
	// Pending amount in cents
	PendingAmount int64 `json:"pending_amount,required"`
	// Transaction result
	Result AccountActivityListResponseFinancialTransactionResult `json:"result,required"`
	// Settled amount in cents
	SettledAmount int64 `json:"settled_amount,required"`
	// The status of the transaction
	Status AccountActivityListResponseFinancialTransactionStatus `json:"status,required"`
	// ISO 8601 timestamp of when the transaction was last updated
	Updated time.Time                                           `json:"updated,required" format:"date-time"`
	JSON    accountActivityListResponseFinancialTransactionJSON `json:"-"`
}

Financial transaction with inheritance from unified base transaction

func (*AccountActivityListResponseFinancialTransaction) UnmarshalJSON added in v0.87.0

func (r *AccountActivityListResponseFinancialTransaction) UnmarshalJSON(data []byte) (err error)

type AccountActivityListResponseFinancialTransactionCategory added in v0.87.0

type AccountActivityListResponseFinancialTransactionCategory string

Transaction category

const (
	AccountActivityListResponseFinancialTransactionCategoryACH                    AccountActivityListResponseFinancialTransactionCategory = "ACH"
	AccountActivityListResponseFinancialTransactionCategoryBalanceOrFunding       AccountActivityListResponseFinancialTransactionCategory = "BALANCE_OR_FUNDING"
	AccountActivityListResponseFinancialTransactionCategoryFee                    AccountActivityListResponseFinancialTransactionCategory = "FEE"
	AccountActivityListResponseFinancialTransactionCategoryReward                 AccountActivityListResponseFinancialTransactionCategory = "REWARD"
	AccountActivityListResponseFinancialTransactionCategoryAdjustment             AccountActivityListResponseFinancialTransactionCategory = "ADJUSTMENT"
	AccountActivityListResponseFinancialTransactionCategoryDerecognition          AccountActivityListResponseFinancialTransactionCategory = "DERECOGNITION"
	AccountActivityListResponseFinancialTransactionCategoryDispute                AccountActivityListResponseFinancialTransactionCategory = "DISPUTE"
	AccountActivityListResponseFinancialTransactionCategoryCard                   AccountActivityListResponseFinancialTransactionCategory = "CARD"
	AccountActivityListResponseFinancialTransactionCategoryExternalACH            AccountActivityListResponseFinancialTransactionCategory = "EXTERNAL_ACH"
	AccountActivityListResponseFinancialTransactionCategoryExternalCheck          AccountActivityListResponseFinancialTransactionCategory = "EXTERNAL_CHECK"
	AccountActivityListResponseFinancialTransactionCategoryExternalFednow         AccountActivityListResponseFinancialTransactionCategory = "EXTERNAL_FEDNOW"
	AccountActivityListResponseFinancialTransactionCategoryExternalRtp            AccountActivityListResponseFinancialTransactionCategory = "EXTERNAL_RTP"
	AccountActivityListResponseFinancialTransactionCategoryExternalTransfer       AccountActivityListResponseFinancialTransactionCategory = "EXTERNAL_TRANSFER"
	AccountActivityListResponseFinancialTransactionCategoryExternalWire           AccountActivityListResponseFinancialTransactionCategory = "EXTERNAL_WIRE"
	AccountActivityListResponseFinancialTransactionCategoryManagementAdjustment   AccountActivityListResponseFinancialTransactionCategory = "MANAGEMENT_ADJUSTMENT"
	AccountActivityListResponseFinancialTransactionCategoryManagementDispute      AccountActivityListResponseFinancialTransactionCategory = "MANAGEMENT_DISPUTE"
	AccountActivityListResponseFinancialTransactionCategoryManagementFee          AccountActivityListResponseFinancialTransactionCategory = "MANAGEMENT_FEE"
	AccountActivityListResponseFinancialTransactionCategoryManagementReward       AccountActivityListResponseFinancialTransactionCategory = "MANAGEMENT_REWARD"
	AccountActivityListResponseFinancialTransactionCategoryManagementDisbursement AccountActivityListResponseFinancialTransactionCategory = "MANAGEMENT_DISBURSEMENT"
	AccountActivityListResponseFinancialTransactionCategoryProgramFunding         AccountActivityListResponseFinancialTransactionCategory = "PROGRAM_FUNDING"
)

func (AccountActivityListResponseFinancialTransactionCategory) IsKnown added in v0.87.0

type AccountActivityListResponseFinancialTransactionFamily added in v0.87.0

type AccountActivityListResponseFinancialTransactionFamily string

INTERNAL - Financial Transaction

const (
	AccountActivityListResponseFinancialTransactionFamilyInternal AccountActivityListResponseFinancialTransactionFamily = "INTERNAL"
)

func (AccountActivityListResponseFinancialTransactionFamily) IsKnown added in v0.87.0

type AccountActivityListResponseFinancialTransactionResult added in v0.87.0

type AccountActivityListResponseFinancialTransactionResult string

Transaction result

const (
	AccountActivityListResponseFinancialTransactionResultApproved AccountActivityListResponseFinancialTransactionResult = "APPROVED"
	AccountActivityListResponseFinancialTransactionResultDeclined AccountActivityListResponseFinancialTransactionResult = "DECLINED"
)

func (AccountActivityListResponseFinancialTransactionResult) IsKnown added in v0.87.0

type AccountActivityListResponseFinancialTransactionStatus added in v0.87.0

type AccountActivityListResponseFinancialTransactionStatus string

The status of the transaction

const (
	AccountActivityListResponseFinancialTransactionStatusPending  AccountActivityListResponseFinancialTransactionStatus = "PENDING"
	AccountActivityListResponseFinancialTransactionStatusSettled  AccountActivityListResponseFinancialTransactionStatus = "SETTLED"
	AccountActivityListResponseFinancialTransactionStatusDeclined AccountActivityListResponseFinancialTransactionStatus = "DECLINED"
	AccountActivityListResponseFinancialTransactionStatusReversed AccountActivityListResponseFinancialTransactionStatus = "REVERSED"
	AccountActivityListResponseFinancialTransactionStatusCanceled AccountActivityListResponseFinancialTransactionStatus = "CANCELED"
	AccountActivityListResponseFinancialTransactionStatusReturned AccountActivityListResponseFinancialTransactionStatus = "RETURNED"
)

func (AccountActivityListResponseFinancialTransactionStatus) IsKnown added in v0.87.0

type AccountActivityListResponseMethod added in v0.87.0

type AccountActivityListResponseMethod string

Transfer method

const (
	AccountActivityListResponseMethodACHNextDay AccountActivityListResponseMethod = "ACH_NEXT_DAY"
	AccountActivityListResponseMethodACHSameDay AccountActivityListResponseMethod = "ACH_SAME_DAY"
	AccountActivityListResponseMethodWire       AccountActivityListResponseMethod = "WIRE"
)

func (AccountActivityListResponseMethod) IsKnown added in v0.87.0

type AccountActivityListResponseNetwork added in v0.87.0

type AccountActivityListResponseNetwork string

Card network of the authorization. Value is `UNKNOWN` when Lithic cannot determine the network code from the upstream provider.

const (
	AccountActivityListResponseNetworkAmex       AccountActivityListResponseNetwork = "AMEX"
	AccountActivityListResponseNetworkInterlink  AccountActivityListResponseNetwork = "INTERLINK"
	AccountActivityListResponseNetworkMaestro    AccountActivityListResponseNetwork = "MAESTRO"
	AccountActivityListResponseNetworkMastercard AccountActivityListResponseNetwork = "MASTERCARD"
	AccountActivityListResponseNetworkUnknown    AccountActivityListResponseNetwork = "UNKNOWN"
	AccountActivityListResponseNetworkVisa       AccountActivityListResponseNetwork = "VISA"
)

func (AccountActivityListResponseNetwork) IsKnown added in v0.87.0

type AccountActivityListResponsePaymentType added in v0.87.0

type AccountActivityListResponsePaymentType string
const (
	AccountActivityListResponsePaymentTypeDeposit    AccountActivityListResponsePaymentType = "DEPOSIT"
	AccountActivityListResponsePaymentTypeWithdrawal AccountActivityListResponsePaymentType = "WITHDRAWAL"
)

func (AccountActivityListResponsePaymentType) IsKnown added in v0.87.0

type AccountActivityListResponseResult added in v0.87.0

type AccountActivityListResponseResult string

Transaction result

const (
	AccountActivityListResponseResultApproved                    AccountActivityListResponseResult = "APPROVED"
	AccountActivityListResponseResultDeclined                    AccountActivityListResponseResult = "DECLINED"
	AccountActivityListResponseResultAccountPaused               AccountActivityListResponseResult = "ACCOUNT_PAUSED"
	AccountActivityListResponseResultAccountStateTransactionFail AccountActivityListResponseResult = "ACCOUNT_STATE_TRANSACTION_FAIL"
	AccountActivityListResponseResultBankConnectionError         AccountActivityListResponseResult = "BANK_CONNECTION_ERROR"
	AccountActivityListResponseResultBankNotVerified             AccountActivityListResponseResult = "BANK_NOT_VERIFIED"
	AccountActivityListResponseResultCardClosed                  AccountActivityListResponseResult = "CARD_CLOSED"
	AccountActivityListResponseResultCardPaused                  AccountActivityListResponseResult = "CARD_PAUSED"
	AccountActivityListResponseResultFraudAdvice                 AccountActivityListResponseResult = "FRAUD_ADVICE"
	AccountActivityListResponseResultIgnoredTtlExpiry            AccountActivityListResponseResult = "IGNORED_TTL_EXPIRY"
	AccountActivityListResponseResultSuspectedFraud              AccountActivityListResponseResult = "SUSPECTED_FRAUD"
	AccountActivityListResponseResultInactiveAccount             AccountActivityListResponseResult = "INACTIVE_ACCOUNT"
	AccountActivityListResponseResultIncorrectPin                AccountActivityListResponseResult = "INCORRECT_PIN"
	AccountActivityListResponseResultInvalidCardDetails          AccountActivityListResponseResult = "INVALID_CARD_DETAILS"
	AccountActivityListResponseResultInsufficientFunds           AccountActivityListResponseResult = "INSUFFICIENT_FUNDS"
	AccountActivityListResponseResultInsufficientFundsPreload    AccountActivityListResponseResult = "INSUFFICIENT_FUNDS_PRELOAD"
	AccountActivityListResponseResultInvalidTransaction          AccountActivityListResponseResult = "INVALID_TRANSACTION"
	AccountActivityListResponseResultMerchantBlacklist           AccountActivityListResponseResult = "MERCHANT_BLACKLIST"
	AccountActivityListResponseResultOriginalNotFound            AccountActivityListResponseResult = "ORIGINAL_NOT_FOUND"
	AccountActivityListResponseResultPreviouslyCompleted         AccountActivityListResponseResult = "PREVIOUSLY_COMPLETED"
	AccountActivityListResponseResultSingleUseRecharged          AccountActivityListResponseResult = "SINGLE_USE_RECHARGED"
	AccountActivityListResponseResultSwitchInoperativeAdvice     AccountActivityListResponseResult = "SWITCH_INOPERATIVE_ADVICE"
	AccountActivityListResponseResultUnauthorizedMerchant        AccountActivityListResponseResult = "UNAUTHORIZED_MERCHANT"
	AccountActivityListResponseResultUnknownHostTimeout          AccountActivityListResponseResult = "UNKNOWN_HOST_TIMEOUT"
	AccountActivityListResponseResultUserTransactionLimit        AccountActivityListResponseResult = "USER_TRANSACTION_LIMIT"
)

func (AccountActivityListResponseResult) IsKnown added in v0.87.0

type AccountActivityListResponseSource added in v0.87.0

type AccountActivityListResponseSource string

Transaction source

const (
	AccountActivityListResponseSourceLithic   AccountActivityListResponseSource = "LITHIC"
	AccountActivityListResponseSourceExternal AccountActivityListResponseSource = "EXTERNAL"
	AccountActivityListResponseSourceCustomer AccountActivityListResponseSource = "CUSTOMER"
)

func (AccountActivityListResponseSource) IsKnown added in v0.87.0

type AccountActivityListResponseStatus added in v0.87.0

type AccountActivityListResponseStatus string

The status of the transaction

const (
	AccountActivityListResponseStatusPending  AccountActivityListResponseStatus = "PENDING"
	AccountActivityListResponseStatusSettled  AccountActivityListResponseStatus = "SETTLED"
	AccountActivityListResponseStatusDeclined AccountActivityListResponseStatus = "DECLINED"
	AccountActivityListResponseStatusReversed AccountActivityListResponseStatus = "REVERSED"
	AccountActivityListResponseStatusCanceled AccountActivityListResponseStatus = "CANCELED"
	AccountActivityListResponseStatusReturned AccountActivityListResponseStatus = "RETURNED"
	AccountActivityListResponseStatusExpired  AccountActivityListResponseStatus = "EXPIRED"
	AccountActivityListResponseStatusVoided   AccountActivityListResponseStatus = "VOIDED"
)

func (AccountActivityListResponseStatus) IsKnown added in v0.87.0

type AccountActivityListResponseType added in v0.90.0

type AccountActivityListResponseType string
const (
	AccountActivityListResponseTypeOriginationCredit   AccountActivityListResponseType = "ORIGINATION_CREDIT"
	AccountActivityListResponseTypeOriginationDebit    AccountActivityListResponseType = "ORIGINATION_DEBIT"
	AccountActivityListResponseTypeReceiptCredit       AccountActivityListResponseType = "RECEIPT_CREDIT"
	AccountActivityListResponseTypeReceiptDebit        AccountActivityListResponseType = "RECEIPT_DEBIT"
	AccountActivityListResponseTypeWireInboundPayment  AccountActivityListResponseType = "WIRE_INBOUND_PAYMENT"
	AccountActivityListResponseTypeWireInboundAdmin    AccountActivityListResponseType = "WIRE_INBOUND_ADMIN"
	AccountActivityListResponseTypeWireOutboundPayment AccountActivityListResponseType = "WIRE_OUTBOUND_PAYMENT"
	AccountActivityListResponseTypeWireOutboundAdmin   AccountActivityListResponseType = "WIRE_OUTBOUND_ADMIN"
)

func (AccountActivityListResponseType) IsKnown added in v0.90.0

type AccountActivityListResponseUnion added in v0.87.0

type AccountActivityListResponseUnion interface {
	// contains filtered or unexported methods
}

Response containing multiple transaction types. The `family` field determines which transaction type is returned: INTERNAL returns FinancialTransaction, TRANSFER returns BookTransferTransaction, CARD returns CardTransaction, PAYMENT returns PaymentTransaction, EXTERNAL_PAYMENT returns ExternalPaymentResponse, and MANAGEMENT_OPERATION returns ManagementOperationTransaction

Union satisfied by AccountActivityListResponseFinancialTransaction, BookTransferResponse, AccountActivityListResponseCardTransaction, Payment, ExternalPayment or ManagementOperationTransaction.

type AccountActivityService added in v0.87.0

type AccountActivityService struct {
	Options []option.RequestOption
}

AccountActivityService contains methods and other services that help with interacting with the lithic API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAccountActivityService method instead.

func NewAccountActivityService added in v0.87.0

func NewAccountActivityService(opts ...option.RequestOption) (r *AccountActivityService)

NewAccountActivityService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*AccountActivityService) GetTransaction added in v0.87.0

func (r *AccountActivityService) GetTransaction(ctx context.Context, transactionToken string, opts ...option.RequestOption) (res *AccountActivityGetTransactionResponse, err error)

Retrieve a single transaction

func (*AccountActivityService) List added in v0.87.0

Retrieve a list of transactions across all public accounts.

func (*AccountActivityService) ListAutoPaging added in v0.87.0

Retrieve a list of transactions across all public accounts.

type AccountHolder

type AccountHolder struct {
	// Globally unique identifier for the account holder.
	Token string `json:"token,required" format:"uuid"`
	// Timestamp of when the account holder was created.
	Created time.Time `json:"created,required" format:"date-time"`
	// Globally unique identifier for the account.
	AccountToken string `json:"account_token" format:"uuid"`
	// Deprecated.
	//
	// Deprecated: deprecated
	BeneficialOwnerEntities []AccountHolderBeneficialOwnerEntity `json:"beneficial_owner_entities"`
	// Only present when user_type == "BUSINESS". You must submit a list of all direct
	// and indirect individuals with 25% or more ownership in the company. A maximum of
	// 4 beneficial owners can be submitted. If no individual owns 25% of the company
	// you do not need to send beneficial owner information. See
	// [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf)
	// (Section I) for more background on individuals that should be included.
	BeneficialOwnerIndividuals []AccountHolderBeneficialOwnerIndividual `json:"beneficial_owner_individuals"`
	// Only applicable for customers using the KYC-Exempt workflow to enroll authorized
	// users of businesses. Pass the account_token of the enrolled business associated
	// with the AUTHORIZED_USER in this field.
	BusinessAccountToken string `json:"business_account_token" format:"uuid"`
	// Only present when user_type == "BUSINESS". Information about the business for
	// which the account is being opened and KYB is being run.
	BusinessEntity AccountHolderBusinessEntity `json:"business_entity"`
	// Only present when user_type == "BUSINESS". An individual with significant
	// responsibility for managing the legal entity (e.g., a Chief Executive Officer,
	// Chief Financial Officer, Chief Operating Officer, Managing Member, General
	// Partner, President, Vice President, or Treasurer). This can be an executive, or
	// someone who will have program-wide access to the cards that Lithic will provide.
	// In some cases, this individual could also be a beneficial owner listed above.
	ControlPerson AccountHolderControlPerson `json:"control_person"`
	// (Deprecated. Use control_person.email when user_type == "BUSINESS". Use
	// individual.phone_number when user_type == "INDIVIDUAL".) Primary email of
	// Account Holder.
	Email string `json:"email"`
	// The type of KYC exemption for a KYC-Exempt Account Holder.
	ExemptionType AccountHolderExemptionType `json:"exemption_type"`
	// Customer-provided token that indicates a relationship with an object outside of
	// the Lithic ecosystem.
	ExternalID string `json:"external_id"`
	// Only present when user_type == "INDIVIDUAL". Information about the individual
	// for which the account is being opened and KYC is being run.
	Individual AccountHolderIndividual `json:"individual"`
	// Only present when user_type == "BUSINESS". User-submitted description of the
	// business.
	NatureOfBusiness string `json:"nature_of_business"`
	// (Deprecated. Use control_person.phone_number when user_type == "BUSINESS". Use
	// individual.phone_number when user_type == "INDIVIDUAL".) Primary phone of
	// Account Holder, entered in E.164 format.
	PhoneNumber string `json:"phone_number"`
	// Only present for "KYB_BASIC" workflow. A list of documents required for the
	// account holder to be approved.
	RequiredDocuments []RequiredDocument `json:"required_documents"`
	// (Deprecated. Use verification_application.status instead)
	//
	// KYC and KYB evaluation states.
	//
	// Note:
	//
	// - `PENDING_REVIEW` is only applicable for the `KYB_BASIC` workflow.
	Status AccountHolderStatus `json:"status"`
	// (Deprecated. Use verification_application.status_reasons)
	//
	// Reason for the evaluation status.
	StatusReasons []AccountHolderStatusReason `json:"status_reasons"`
	// The type of Account Holder. If the type is "INDIVIDUAL", the "individual"
	// attribute will be present. If the type is "BUSINESS" then the "business_entity",
	// "control_person", "beneficial_owner_individuals", "nature_of_business", and
	// "website_url" attributes will be present.
	UserType AccountHolderUserType `json:"user_type"`
	// Information about the most recent identity verification attempt
	VerificationApplication AccountHolderVerificationApplication `json:"verification_application"`
	// Only present when user_type == "BUSINESS". Business's primary website.
	WebsiteURL string            `json:"website_url"`
	JSON       accountHolderJSON `json:"-"`
}

func (*AccountHolder) UnmarshalJSON

func (r *AccountHolder) UnmarshalJSON(data []byte) (err error)

type AccountHolderBeneficialOwnerEntity added in v0.8.0

type AccountHolderBeneficialOwnerEntity struct {
	// Business's physical address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable.
	Address shared.Address `json:"address,required"`
	// Any name that the business operates under that is not its legal business name
	// (if applicable).
	DbaBusinessName string `json:"dba_business_name,required"`
	// Globally unique identifier for the entity.
	EntityToken string `json:"entity_token,required" format:"uuid"`
	// Government-issued identification number. US Federal Employer Identification
	// Numbers (EIN) are currently supported, entered as full nine-digits, with or
	// without hyphens.
	GovernmentID string `json:"government_id,required"`
	// Legal (formal) business name.
	LegalBusinessName string `json:"legal_business_name,required"`
	// One or more of the business's phone number(s), entered as a list in E.164
	// format.
	PhoneNumbers []string `json:"phone_numbers,required"`
	// Parent company name (if applicable).
	ParentCompany string                                 `json:"parent_company"`
	JSON          accountHolderBeneficialOwnerEntityJSON `json:"-"`
}

func (*AccountHolderBeneficialOwnerEntity) UnmarshalJSON added in v0.8.0

func (r *AccountHolderBeneficialOwnerEntity) UnmarshalJSON(data []byte) (err error)

type AccountHolderBeneficialOwnerIndividual added in v0.8.0

type AccountHolderBeneficialOwnerIndividual struct {
	// Individual's current address
	Address shared.Address `json:"address,required"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob string `json:"dob,required"`
	// Individual's email address.
	Email string `json:"email,required"`
	// Globally unique identifier for the entity.
	EntityToken string `json:"entity_token,required" format:"uuid"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName string `json:"first_name,required"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName string `json:"last_name,required"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber string                                     `json:"phone_number,required"`
	JSON        accountHolderBeneficialOwnerIndividualJSON `json:"-"`
}

Information about an individual associated with an account holder. A subset of the information provided via KYC. For example, we do not return the government id.

func (*AccountHolderBeneficialOwnerIndividual) UnmarshalJSON added in v0.8.0

func (r *AccountHolderBeneficialOwnerIndividual) UnmarshalJSON(data []byte) (err error)

type AccountHolderBusinessEntity added in v0.8.0

type AccountHolderBusinessEntity struct {
	// Business's physical address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable.
	Address shared.Address `json:"address,required"`
	// Any name that the business operates under that is not its legal business name
	// (if applicable).
	DbaBusinessName string `json:"dba_business_name,required"`
	// Globally unique identifier for the entity.
	EntityToken string `json:"entity_token,required" format:"uuid"`
	// Government-issued identification number. US Federal Employer Identification
	// Numbers (EIN) are currently supported, entered as full nine-digits, with or
	// without hyphens.
	GovernmentID string `json:"government_id,required"`
	// Legal (formal) business name.
	LegalBusinessName string `json:"legal_business_name,required"`
	// One or more of the business's phone number(s), entered as a list in E.164
	// format.
	PhoneNumbers []string `json:"phone_numbers,required"`
	// Parent company name (if applicable).
	ParentCompany string                          `json:"parent_company"`
	JSON          accountHolderBusinessEntityJSON `json:"-"`
}

Only present when user_type == "BUSINESS". Information about the business for which the account is being opened and KYB is being run.

func (*AccountHolderBusinessEntity) UnmarshalJSON added in v0.8.0

func (r *AccountHolderBusinessEntity) UnmarshalJSON(data []byte) (err error)

type AccountHolderControlPerson added in v0.8.0

type AccountHolderControlPerson struct {
	// Individual's current address
	Address shared.Address `json:"address,required"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob string `json:"dob,required"`
	// Individual's email address.
	Email string `json:"email,required"`
	// Globally unique identifier for the entity.
	EntityToken string `json:"entity_token,required" format:"uuid"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName string `json:"first_name,required"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName string `json:"last_name,required"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber string                         `json:"phone_number,required"`
	JSON        accountHolderControlPersonJSON `json:"-"`
}

Only present when user_type == "BUSINESS". An individual with significant responsibility for managing the legal entity (e.g., a Chief Executive Officer, Chief Financial Officer, Chief Operating Officer, Managing Member, General Partner, President, Vice President, or Treasurer). This can be an executive, or someone who will have program-wide access to the cards that Lithic will provide. In some cases, this individual could also be a beneficial owner listed above.

func (*AccountHolderControlPerson) UnmarshalJSON added in v0.8.0

func (r *AccountHolderControlPerson) UnmarshalJSON(data []byte) (err error)

type AccountHolderCreatedWebhookEvent added in v0.98.0

type AccountHolderCreatedWebhookEvent struct {
	// The type of event that occurred.
	EventType AccountHolderCreatedWebhookEventEventType `json:"event_type,required"`
	// The token of the account_holder that was created.
	Token string `json:"token" format:"uuid"`
	// The token of the account that was created.
	AccountToken string `json:"account_token" format:"uuid"`
	// When the account_holder was created
	Created           time.Time          `json:"created" format:"date-time"`
	RequiredDocuments []RequiredDocument `json:"required_documents"`
	// The status of the account_holder that was created.
	Status       AccountHolderCreatedWebhookEventStatus `json:"status"`
	StatusReason []string                               `json:"status_reason"`
	JSON         accountHolderCreatedWebhookEventJSON   `json:"-"`
}

func (*AccountHolderCreatedWebhookEvent) UnmarshalJSON added in v0.98.0

func (r *AccountHolderCreatedWebhookEvent) UnmarshalJSON(data []byte) (err error)

type AccountHolderCreatedWebhookEventEventType added in v0.98.0

type AccountHolderCreatedWebhookEventEventType string

The type of event that occurred.

const (
	AccountHolderCreatedWebhookEventEventTypeAccountHolderCreated AccountHolderCreatedWebhookEventEventType = "account_holder.created"
)

func (AccountHolderCreatedWebhookEventEventType) IsKnown added in v0.98.0

type AccountHolderCreatedWebhookEventStatus added in v0.98.0

type AccountHolderCreatedWebhookEventStatus string

The status of the account_holder that was created.

const (
	AccountHolderCreatedWebhookEventStatusAccepted      AccountHolderCreatedWebhookEventStatus = "ACCEPTED"
	AccountHolderCreatedWebhookEventStatusPendingReview AccountHolderCreatedWebhookEventStatus = "PENDING_REVIEW"
)

func (AccountHolderCreatedWebhookEventStatus) IsKnown added in v0.98.0

type AccountHolderDocumentUpdatedWebhookEvent added in v0.98.0

type AccountHolderDocumentUpdatedWebhookEvent struct {
	// The type of event that occurred.
	EventType AccountHolderDocumentUpdatedWebhookEventEventType `json:"event_type,required"`
	// The token of the account holder document
	Token string `json:"token" format:"uuid"`
	// The token of the account_holder that the document belongs to
	AccountHolderToken string `json:"account_holder_token" format:"uuid"`
	// When the account_holder was created
	Created time.Time `json:"created" format:"date-time"`
	// Type of documentation to be submitted for verification of an account holder
	DocumentType AccountHolderDocumentUpdatedWebhookEventDocumentType `json:"document_type"`
	// The token of the entity that the document belongs to
	EntityToken             string                                                           `json:"entity_token" format:"uuid"`
	RequiredDocumentUploads []AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUpload `json:"required_document_uploads"`
	JSON                    accountHolderDocumentUpdatedWebhookEventJSON                     `json:"-"`
}

func (*AccountHolderDocumentUpdatedWebhookEvent) UnmarshalJSON added in v0.98.0

func (r *AccountHolderDocumentUpdatedWebhookEvent) UnmarshalJSON(data []byte) (err error)

type AccountHolderDocumentUpdatedWebhookEventDocumentType added in v0.98.0

type AccountHolderDocumentUpdatedWebhookEventDocumentType string

Type of documentation to be submitted for verification of an account holder

const (
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeDriversLicense            AccountHolderDocumentUpdatedWebhookEventDocumentType = "DRIVERS_LICENSE"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypePassport                  AccountHolderDocumentUpdatedWebhookEventDocumentType = "PASSPORT"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypePassportCard              AccountHolderDocumentUpdatedWebhookEventDocumentType = "PASSPORT_CARD"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeEinLetter                 AccountHolderDocumentUpdatedWebhookEventDocumentType = "EIN_LETTER"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeTaxReturn                 AccountHolderDocumentUpdatedWebhookEventDocumentType = "TAX_RETURN"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeOperatingAgreement        AccountHolderDocumentUpdatedWebhookEventDocumentType = "OPERATING_AGREEMENT"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeCertificateOfFormation    AccountHolderDocumentUpdatedWebhookEventDocumentType = "CERTIFICATE_OF_FORMATION"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeCertificateOfGoodStanding AccountHolderDocumentUpdatedWebhookEventDocumentType = "CERTIFICATE_OF_GOOD_STANDING"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeArticlesOfIncorporation   AccountHolderDocumentUpdatedWebhookEventDocumentType = "ARTICLES_OF_INCORPORATION"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeArticlesOfOrganization    AccountHolderDocumentUpdatedWebhookEventDocumentType = "ARTICLES_OF_ORGANIZATION"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeBylaws                    AccountHolderDocumentUpdatedWebhookEventDocumentType = "BYLAWS"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeGovernmentBusinessLicense AccountHolderDocumentUpdatedWebhookEventDocumentType = "GOVERNMENT_BUSINESS_LICENSE"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypePartnershipAgreement      AccountHolderDocumentUpdatedWebhookEventDocumentType = "PARTNERSHIP_AGREEMENT"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeSs4Form                   AccountHolderDocumentUpdatedWebhookEventDocumentType = "SS4_FORM"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeBankStatement             AccountHolderDocumentUpdatedWebhookEventDocumentType = "BANK_STATEMENT"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeUtilityBillStatement      AccountHolderDocumentUpdatedWebhookEventDocumentType = "UTILITY_BILL_STATEMENT"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeSsnCard                   AccountHolderDocumentUpdatedWebhookEventDocumentType = "SSN_CARD"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeItinLetter                AccountHolderDocumentUpdatedWebhookEventDocumentType = "ITIN_LETTER"
	AccountHolderDocumentUpdatedWebhookEventDocumentTypeFincenBoiReport           AccountHolderDocumentUpdatedWebhookEventDocumentType = "FINCEN_BOI_REPORT"
)

func (AccountHolderDocumentUpdatedWebhookEventDocumentType) IsKnown added in v0.98.0

type AccountHolderDocumentUpdatedWebhookEventEventType added in v0.98.0

type AccountHolderDocumentUpdatedWebhookEventEventType string

The type of event that occurred.

const (
	AccountHolderDocumentUpdatedWebhookEventEventTypeAccountHolderDocumentUpdated AccountHolderDocumentUpdatedWebhookEventEventType = "account_holder_document.updated"
)

func (AccountHolderDocumentUpdatedWebhookEventEventType) IsKnown added in v0.98.0

type AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUpload added in v0.98.0

type AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUpload struct {
	// The token of the document upload
	Token                       string   `json:"token" format:"uuid"`
	AcceptedEntityStatusReasons []string `json:"accepted_entity_status_reasons"`
	// When the document upload was created
	Created time.Time `json:"created" format:"date-time"`
	// The type of image that was uploaded
	ImageType                   AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsImageType `json:"image_type"`
	RejectedEntityStatusReasons []string                                                                 `json:"rejected_entity_status_reasons"`
	// The status of the document upload
	Status        AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatus `json:"status"`
	StatusReasons []string                                                              `json:"status_reasons"`
	// When the document upload was last updated
	Updated time.Time                                                          `json:"updated" format:"date-time"`
	JSON    accountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadJSON `json:"-"`
}

A document upload that belongs to the overall account holder document

func (*AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUpload) UnmarshalJSON added in v0.98.0

type AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsImageType added in v0.98.0

type AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsImageType string

The type of image that was uploaded

const (
	AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsImageTypeFront AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsImageType = "FRONT"
	AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsImageTypeBack  AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsImageType = "BACK"
)

func (AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsImageType) IsKnown added in v0.98.0

type AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatus added in v0.98.0

type AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatus string

The status of the document upload

const (
	AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatusAccepted        AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatus = "ACCEPTED"
	AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatusRejected        AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatus = "REJECTED"
	AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatusPendingUpload   AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatus = "PENDING_UPLOAD"
	AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatusUploaded        AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatus = "UPLOADED"
	AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatusPartialApproval AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatus = "PARTIAL_APPROVAL"
)

func (AccountHolderDocumentUpdatedWebhookEventRequiredDocumentUploadsStatus) IsKnown added in v0.98.0

type AccountHolderExemptionType added in v0.8.0

type AccountHolderExemptionType string

The type of KYC exemption for a KYC-Exempt Account Holder.

const (
	AccountHolderExemptionTypeAuthorizedUser  AccountHolderExemptionType = "AUTHORIZED_USER"
	AccountHolderExemptionTypePrepaidCardUser AccountHolderExemptionType = "PREPAID_CARD_USER"
)

func (AccountHolderExemptionType) IsKnown added in v0.27.0

func (r AccountHolderExemptionType) IsKnown() bool

type AccountHolderIndividual added in v0.8.0

type AccountHolderIndividual struct {
	// Individual's current address
	Address shared.Address `json:"address,required"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob string `json:"dob,required"`
	// Individual's email address.
	Email string `json:"email,required"`
	// Globally unique identifier for the entity.
	EntityToken string `json:"entity_token,required" format:"uuid"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName string `json:"first_name,required"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName string `json:"last_name,required"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber string                      `json:"phone_number,required"`
	JSON        accountHolderIndividualJSON `json:"-"`
}

Only present when user_type == "INDIVIDUAL". Information about the individual for which the account is being opened and KYC is being run.

func (*AccountHolderIndividual) UnmarshalJSON added in v0.8.0

func (r *AccountHolderIndividual) UnmarshalJSON(data []byte) (err error)

type AccountHolderListDocumentsResponse

type AccountHolderListDocumentsResponse struct {
	Data []shared.Document                      `json:"data"`
	JSON accountHolderListDocumentsResponseJSON `json:"-"`
}

func (*AccountHolderListDocumentsResponse) UnmarshalJSON

func (r *AccountHolderListDocumentsResponse) UnmarshalJSON(data []byte) (err error)

type AccountHolderListParams added in v0.19.1

type AccountHolderListParams struct {
	// Date string in RFC 3339 format. Only entries created after the specified time
	// will be included. UTC time zone.
	Begin param.Field[time.Time] `query:"begin" format:"date-time"`
	// Email address of the account holder. The query must be an exact match, case
	// insensitive.
	Email param.Field[string] `query:"email"`
	// Date string in RFC 3339 format. Only entries created before the specified time
	// will be included. UTC time zone.
	End param.Field[time.Time] `query:"end" format:"date-time"`
	// A cursor representing an item's token before which a page of results should end.
	// Used to retrieve the previous page of results before this item.
	EndingBefore param.Field[string] `query:"ending_before"`
	// If applicable, represents the external_id associated with the account_holder.
	ExternalID param.Field[string] `query:"external_id" format:"uuid"`
	// (Individual Account Holders only) The first name of the account holder. The
	// query is case insensitive and supports partial matches.
	FirstName param.Field[string] `query:"first_name"`
	// (Individual Account Holders only) The last name of the account holder. The query
	// is case insensitive and supports partial matches.
	LastName param.Field[string] `query:"last_name"`
	// (Business Account Holders only) The legal business name of the account holder.
	// The query is case insensitive and supports partial matches.
	LegalBusinessName param.Field[string] `query:"legal_business_name"`
	// The number of account_holders to limit the response to.
	Limit param.Field[int64] `query:"limit"`
	// Phone number of the account holder. The query must be an exact match.
	PhoneNumber param.Field[string] `query:"phone_number"`
	// A cursor representing an item's token after which a page of results should
	// begin. Used to retrieve the next page of results after this item.
	StartingAfter param.Field[string] `query:"starting_after"`
}

func (AccountHolderListParams) URLQuery added in v0.19.1

func (r AccountHolderListParams) URLQuery() (v url.Values)

URLQuery serializes AccountHolderListParams's query parameters as `url.Values`.

type AccountHolderNewParams

type AccountHolderNewParams struct {
	Body AccountHolderNewParamsBodyUnion `json:"body,required"`
}

func (AccountHolderNewParams) MarshalJSON added in v0.29.0

func (r AccountHolderNewParams) MarshalJSON() (data []byte, err error)

type AccountHolderNewParamsBody added in v0.29.0

type AccountHolderNewParamsBody struct {
	// KYC Exempt user's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable.
	Address                    param.Field[shared.AddressParam] `json:"address"`
	BeneficialOwnerEntities    param.Field[interface{}]         `json:"beneficial_owner_entities"`
	BeneficialOwnerIndividuals param.Field[interface{}]         `json:"beneficial_owner_individuals"`
	// Only applicable for customers using the KYC-Exempt workflow to enroll authorized
	// users of businesses. Pass the account_token of the enrolled business associated
	// with the AUTHORIZED_USER in this field.
	BusinessAccountToken param.Field[string]      `json:"business_account_token"`
	BusinessEntity       param.Field[interface{}] `json:"business_entity"`
	ControlPerson        param.Field[interface{}] `json:"control_person"`
	// The KYC Exempt user's email
	Email param.Field[string] `json:"email"`
	// A user provided id that can be used to link an account holder with an external
	// system
	ExternalID param.Field[string] `json:"external_id"`
	// The KYC Exempt user's first name
	FirstName  param.Field[string]      `json:"first_name"`
	Individual param.Field[interface{}] `json:"individual"`
	// An RFC 3339 timestamp indicating when precomputed KYB was completed on the
	// business with a pass result.
	//
	// This field is required only if workflow type is `KYB_BYO`.
	KYBPassedTimestamp param.Field[string] `json:"kyb_passed_timestamp"`
	// Specifies the type of KYC Exempt user
	KYCExemptionType param.Field[AccountHolderNewParamsBodyKYCExemptionType] `json:"kyc_exemption_type"`
	// An RFC 3339 timestamp indicating when precomputed KYC was completed on the
	// individual with a pass result.
	//
	// This field is required only if workflow type is `KYC_BYO`.
	KYCPassedTimestamp param.Field[string] `json:"kyc_passed_timestamp"`
	// The KYC Exempt user's last name
	LastName param.Field[string] `json:"last_name"`
	// Short description of the company's line of business (i.e., what does the company
	// do?).
	NatureOfBusiness param.Field[string] `json:"nature_of_business"`
	// The KYC Exempt user's phone number, entered in E.164 format.
	PhoneNumber param.Field[string] `json:"phone_number"`
	// An RFC 3339 timestamp indicating when the account holder accepted the applicable
	// legal agreements (e.g., cardholder terms) as agreed upon during API customer's
	// implementation with Lithic.
	TosTimestamp param.Field[string] `json:"tos_timestamp"`
	// Company website URL.
	WebsiteURL param.Field[string] `json:"website_url"`
	// Specifies the type of KYB workflow to run.
	Workflow param.Field[AccountHolderNewParamsBodyWorkflow] `json:"workflow"`
}

func (AccountHolderNewParamsBody) MarshalJSON added in v0.29.0

func (r AccountHolderNewParamsBody) MarshalJSON() (data []byte, err error)

type AccountHolderNewParamsBodyKYBDelegated added in v0.90.0

type AccountHolderNewParamsBodyKYBDelegated struct {
	// Information for business for which the account is being opened.
	BusinessEntity param.Field[AccountHolderNewParamsBodyKYBDelegatedBusinessEntity] `json:"business_entity,required"`
	// You can submit a list of all direct and indirect individuals with 25% or more
	// ownership in the company. A maximum of 4 beneficial owners can be submitted. If
	// no individual owns 25% of the company you do not need to send beneficial owner
	// information. See
	// [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf)
	// (Section I) for more background on individuals that should be included.
	BeneficialOwnerIndividuals param.Field[[]AccountHolderNewParamsBodyKYBDelegatedBeneficialOwnerIndividual] `json:"beneficial_owner_individuals"`
	// An individual with significant responsibility for managing the legal entity
	// (e.g., a Chief Executive Officer, Chief Financial Officer, Chief Operating
	// Officer, Managing Member, General Partner, President, Vice President, or
	// Treasurer). This can be an executive, or someone who will have program-wide
	// access to the cards that Lithic will provide. In some cases, this individual
	// could also be a beneficial owner listed above. See
	// [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf)
	// (Section II) for more background.
	ControlPerson param.Field[AccountHolderNewParamsBodyKYBDelegatedControlPerson] `json:"control_person"`
	// A user provided id that can be used to link an account holder with an external
	// system
	ExternalID param.Field[string] `json:"external_id"`
	// Short description of the company's line of business (i.e., what does the company
	// do?).
	NatureOfBusiness param.Field[string] `json:"nature_of_business"`
	// An RFC 3339 timestamp indicating when the account holder accepted the applicable
	// legal agreements (e.g., cardholder terms) as agreed upon during API customer's
	// implementation with Lithic.
	TosTimestamp param.Field[string] `json:"tos_timestamp"`
	// Company website URL.
	WebsiteURL param.Field[string] `json:"website_url"`
	// Specifies the type of KYB workflow to run.
	Workflow param.Field[AccountHolderNewParamsBodyKYBDelegatedWorkflow] `json:"workflow"`
}

func (AccountHolderNewParamsBodyKYBDelegated) MarshalJSON added in v0.90.0

func (r AccountHolderNewParamsBodyKYBDelegated) MarshalJSON() (data []byte, err error)

type AccountHolderNewParamsBodyKYBDelegatedBeneficialOwnerIndividual added in v0.90.0

type AccountHolderNewParamsBodyKYBDelegatedBeneficialOwnerIndividual struct {
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address param.Field[shared.AddressParam] `json:"address,required"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob param.Field[string] `json:"dob,required"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email param.Field[string] `json:"email,required"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName param.Field[string] `json:"first_name,required"`
	// Government-issued identification number (required for identity verification and
	// compliance with banking regulations). Social Security Numbers (SSN) and
	// Individual Taxpayer Identification Numbers (ITIN) are currently supported,
	// entered as full nine-digits, with or without hyphens
	GovernmentID param.Field[string] `json:"government_id,required"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName param.Field[string] `json:"last_name,required"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber param.Field[string] `json:"phone_number"`
}

Individuals associated with a KYB application. Phone number is optional.

func (AccountHolderNewParamsBodyKYBDelegatedBeneficialOwnerIndividual) MarshalJSON added in v0.90.0

type AccountHolderNewParamsBodyKYBDelegatedBusinessEntity added in v0.90.0

type AccountHolderNewParamsBodyKYBDelegatedBusinessEntity struct {
	// Business's physical address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable.
	Address param.Field[shared.AddressParam] `json:"address,required"`
	// Legal (formal) business name.
	LegalBusinessName param.Field[string] `json:"legal_business_name,required"`
	// Any name that the business operates under that is not its legal business name
	// (if applicable).
	DbaBusinessName param.Field[string] `json:"dba_business_name"`
	// Government-issued identification number. US Federal Employer Identification
	// Numbers (EIN) are currently supported, entered as full nine-digits, with or
	// without hyphens.
	GovernmentID param.Field[string] `json:"government_id"`
	// Parent company name (if applicable).
	ParentCompany param.Field[string] `json:"parent_company"`
	// One or more of the business's phone number(s), entered as a list in E.164
	// format.
	PhoneNumbers param.Field[[]string] `json:"phone_numbers"`
}

Information for business for which the account is being opened.

func (AccountHolderNewParamsBodyKYBDelegatedBusinessEntity) MarshalJSON added in v0.90.0

func (r AccountHolderNewParamsBodyKYBDelegatedBusinessEntity) MarshalJSON() (data []byte, err error)

type AccountHolderNewParamsBodyKYBDelegatedControlPerson added in v0.90.0

type AccountHolderNewParamsBodyKYBDelegatedControlPerson struct {
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address param.Field[shared.AddressParam] `json:"address,required"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob param.Field[string] `json:"dob,required"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email param.Field[string] `json:"email,required"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName param.Field[string] `json:"first_name,required"`
	// Government-issued identification number (required for identity verification and
	// compliance with banking regulations). Social Security Numbers (SSN) and
	// Individual Taxpayer Identification Numbers (ITIN) are currently supported,
	// entered as full nine-digits, with or without hyphens
	GovernmentID param.Field[string] `json:"government_id,required"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName param.Field[string] `json:"last_name,required"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber param.Field[string] `json:"phone_number"`
}

An individual with significant responsibility for managing the legal entity (e.g., a Chief Executive Officer, Chief Financial Officer, Chief Operating Officer, Managing Member, General Partner, President, Vice President, or Treasurer). This can be an executive, or someone who will have program-wide access to the cards that Lithic will provide. In some cases, this individual could also be a beneficial owner listed above. See [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf) (Section II) for more background.

func (AccountHolderNewParamsBodyKYBDelegatedControlPerson) MarshalJSON added in v0.90.0

func (r AccountHolderNewParamsBodyKYBDelegatedControlPerson) MarshalJSON() (data []byte, err error)

type AccountHolderNewParamsBodyKYBDelegatedWorkflow added in v0.90.0

type AccountHolderNewParamsBodyKYBDelegatedWorkflow string

Specifies the type of KYB workflow to run.

const (
	AccountHolderNewParamsBodyKYBDelegatedWorkflowKYBDelegated AccountHolderNewParamsBodyKYBDelegatedWorkflow = "KYB_DELEGATED"
)

func (AccountHolderNewParamsBodyKYBDelegatedWorkflow) IsKnown added in v0.90.0

type AccountHolderNewParamsBodyKYCExemptionType added in v0.29.0

type AccountHolderNewParamsBodyKYCExemptionType string

Specifies the type of KYC Exempt user

const (
	AccountHolderNewParamsBodyKYCExemptionTypeAuthorizedUser  AccountHolderNewParamsBodyKYCExemptionType = "AUTHORIZED_USER"
	AccountHolderNewParamsBodyKYCExemptionTypePrepaidCardUser AccountHolderNewParamsBodyKYCExemptionType = "PREPAID_CARD_USER"
)

func (AccountHolderNewParamsBodyKYCExemptionType) IsKnown added in v0.29.0

type AccountHolderNewParamsBodyUnion added in v0.29.0

type AccountHolderNewParamsBodyUnion interface {
	// contains filtered or unexported methods
}

Satisfied by KYBParam, AccountHolderNewParamsBodyKYBDelegated, KYCParam, KYCExemptParam, AccountHolderNewParamsBody.

type AccountHolderNewParamsBodyWorkflow added in v0.29.0

type AccountHolderNewParamsBodyWorkflow string

Specifies the type of KYB workflow to run.

const (
	AccountHolderNewParamsBodyWorkflowKYBBasic     AccountHolderNewParamsBodyWorkflow = "KYB_BASIC"
	AccountHolderNewParamsBodyWorkflowKYBByo       AccountHolderNewParamsBodyWorkflow = "KYB_BYO"
	AccountHolderNewParamsBodyWorkflowKYBDelegated AccountHolderNewParamsBodyWorkflow = "KYB_DELEGATED"
	AccountHolderNewParamsBodyWorkflowKYCBasic     AccountHolderNewParamsBodyWorkflow = "KYC_BASIC"
	AccountHolderNewParamsBodyWorkflowKYCByo       AccountHolderNewParamsBodyWorkflow = "KYC_BYO"
	AccountHolderNewParamsBodyWorkflowKYCExempt    AccountHolderNewParamsBodyWorkflow = "KYC_EXEMPT"
)

func (AccountHolderNewParamsBodyWorkflow) IsKnown added in v0.29.0

type AccountHolderNewResponse added in v0.20.0

type AccountHolderNewResponse struct {
	// Globally unique identifier for the account holder.
	Token string `json:"token,required" format:"uuid"`
	// Globally unique identifier for the account.
	AccountToken string `json:"account_token,required" format:"uuid"`
	// KYC and KYB evaluation states.
	//
	// Note:
	//
	// - `PENDING_REVIEW` is only applicable for the `KYB_BASIC` workflow.
	Status AccountHolderNewResponseStatus `json:"status,required"`
	// Reason for the evaluation status.
	StatusReasons []AccountHolderNewResponseStatusReason `json:"status_reasons,required"`
	// Timestamp of when the account holder was created.
	Created time.Time `json:"created" format:"date-time"`
	// Customer-provided token that indicates a relationship with an object outside of
	// the Lithic ecosystem.
	ExternalID string `json:"external_id"`
	// Only present for "KYB_BASIC" workflow. A list of documents required for the
	// account holder to be approved.
	RequiredDocuments []RequiredDocument           `json:"required_documents"`
	JSON              accountHolderNewResponseJSON `json:"-"`
}

func (*AccountHolderNewResponse) UnmarshalJSON added in v0.20.0

func (r *AccountHolderNewResponse) UnmarshalJSON(data []byte) (err error)

type AccountHolderNewResponseStatus added in v0.20.0

type AccountHolderNewResponseStatus string

KYC and KYB evaluation states.

Note:

- `PENDING_REVIEW` is only applicable for the `KYB_BASIC` workflow.

const (
	AccountHolderNewResponseStatusAccepted        AccountHolderNewResponseStatus = "ACCEPTED"
	AccountHolderNewResponseStatusPendingReview   AccountHolderNewResponseStatus = "PENDING_REVIEW"
	AccountHolderNewResponseStatusPendingDocument AccountHolderNewResponseStatus = "PENDING_DOCUMENT"
	AccountHolderNewResponseStatusPendingResubmit AccountHolderNewResponseStatus = "PENDING_RESUBMIT"
	AccountHolderNewResponseStatusRejected        AccountHolderNewResponseStatus = "REJECTED"
)

func (AccountHolderNewResponseStatus) IsKnown added in v0.27.0

type AccountHolderNewResponseStatusReason added in v0.20.0

type AccountHolderNewResponseStatusReason string

Status Reasons for KYC/KYB enrollment states

const (
	AccountHolderNewResponseStatusReasonAddressVerificationFailure                      AccountHolderNewResponseStatusReason = "ADDRESS_VERIFICATION_FAILURE"
	AccountHolderNewResponseStatusReasonAgeThresholdFailure                             AccountHolderNewResponseStatusReason = "AGE_THRESHOLD_FAILURE"
	AccountHolderNewResponseStatusReasonCompleteVerificationFailure                     AccountHolderNewResponseStatusReason = "COMPLETE_VERIFICATION_FAILURE"
	AccountHolderNewResponseStatusReasonDobVerificationFailure                          AccountHolderNewResponseStatusReason = "DOB_VERIFICATION_FAILURE"
	AccountHolderNewResponseStatusReasonIDVerificationFailure                           AccountHolderNewResponseStatusReason = "ID_VERIFICATION_FAILURE"
	AccountHolderNewResponseStatusReasonMaxDocumentAttempts                             AccountHolderNewResponseStatusReason = "MAX_DOCUMENT_ATTEMPTS"
	AccountHolderNewResponseStatusReasonMaxResubmissionAttempts                         AccountHolderNewResponseStatusReason = "MAX_RESUBMISSION_ATTEMPTS"
	AccountHolderNewResponseStatusReasonNameVerificationFailure                         AccountHolderNewResponseStatusReason = "NAME_VERIFICATION_FAILURE"
	AccountHolderNewResponseStatusReasonOtherVerificationFailure                        AccountHolderNewResponseStatusReason = "OTHER_VERIFICATION_FAILURE"
	AccountHolderNewResponseStatusReasonRiskThresholdFailure                            AccountHolderNewResponseStatusReason = "RISK_THRESHOLD_FAILURE"
	AccountHolderNewResponseStatusReasonWatchlistAlertFailure                           AccountHolderNewResponseStatusReason = "WATCHLIST_ALERT_FAILURE"
	AccountHolderNewResponseStatusReasonPrimaryBusinessEntityIDVerificationFailure      AccountHolderNewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_ID_VERIFICATION_FAILURE"
	AccountHolderNewResponseStatusReasonPrimaryBusinessEntityAddressVerificationFailure AccountHolderNewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_ADDRESS_VERIFICATION_FAILURE"
	AccountHolderNewResponseStatusReasonPrimaryBusinessEntityNameVerificationFailure    AccountHolderNewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_NAME_VERIFICATION_FAILURE"
	AccountHolderNewResponseStatusReasonPrimaryBusinessEntityBusinessOfficersNotMatched AccountHolderNewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_BUSINESS_OFFICERS_NOT_MATCHED"
	AccountHolderNewResponseStatusReasonPrimaryBusinessEntitySosFilingInactive          AccountHolderNewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_SOS_FILING_INACTIVE"
	AccountHolderNewResponseStatusReasonPrimaryBusinessEntitySosNotMatched              AccountHolderNewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_SOS_NOT_MATCHED"
	AccountHolderNewResponseStatusReasonPrimaryBusinessEntityCmraFailure                AccountHolderNewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_CMRA_FAILURE"
	AccountHolderNewResponseStatusReasonPrimaryBusinessEntityWatchlistFailure           AccountHolderNewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_WATCHLIST_FAILURE"
	AccountHolderNewResponseStatusReasonPrimaryBusinessEntityRegisteredAgentFailure     AccountHolderNewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_REGISTERED_AGENT_FAILURE"
	AccountHolderNewResponseStatusReasonControlPersonBlocklistAlertFailure              AccountHolderNewResponseStatusReason = "CONTROL_PERSON_BLOCKLIST_ALERT_FAILURE"
	AccountHolderNewResponseStatusReasonControlPersonIDVerificationFailure              AccountHolderNewResponseStatusReason = "CONTROL_PERSON_ID_VERIFICATION_FAILURE"
	AccountHolderNewResponseStatusReasonControlPersonDobVerificationFailure             AccountHolderNewResponseStatusReason = "CONTROL_PERSON_DOB_VERIFICATION_FAILURE"
	AccountHolderNewResponseStatusReasonControlPersonNameVerificationFailure            AccountHolderNewResponseStatusReason = "CONTROL_PERSON_NAME_VERIFICATION_FAILURE"
)

func (AccountHolderNewResponseStatusReason) IsKnown added in v0.27.0

type AccountHolderService

type AccountHolderService struct {
	Options []option.RequestOption
}

AccountHolderService contains methods and other services that help with interacting with the lithic API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAccountHolderService method instead.

func NewAccountHolderService

func NewAccountHolderService(opts ...option.RequestOption) (r *AccountHolderService)

NewAccountHolderService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*AccountHolderService) Get

func (r *AccountHolderService) Get(ctx context.Context, accountHolderToken string, opts ...option.RequestOption) (res *AccountHolder, err error)

Get an Individual or Business Account Holder and/or their KYC or KYB evaluation status.

func (*AccountHolderService) GetDocument

func (r *AccountHolderService) GetDocument(ctx context.Context, accountHolderToken string, documentToken string, opts ...option.RequestOption) (res *shared.Document, err error)

Check the status of an account holder document upload, or retrieve the upload URLs to process your image uploads.

Note that this is not equivalent to checking the status of the KYC evaluation overall (a document may be successfully uploaded but not be sufficient for KYC to pass).

In the event your upload URLs have expired, calling this endpoint will refresh them. Similarly, in the event a document upload has failed, you can use this endpoint to get a new upload URL for the failed image upload.

When a new account holder document upload is generated for a failed attempt, the response will show an additional entry in the `required_document_uploads` array in a `PENDING` state for the corresponding `image_type`.

func (*AccountHolderService) List added in v0.19.1

Get a list of individual or business account holders and their KYC or KYB evaluation status.

func (*AccountHolderService) ListAutoPaging added in v0.19.1

Get a list of individual or business account holders and their KYC or KYB evaluation status.

func (*AccountHolderService) ListDocuments

func (r *AccountHolderService) ListDocuments(ctx context.Context, accountHolderToken string, opts ...option.RequestOption) (res *AccountHolderListDocumentsResponse, err error)

Retrieve the status of account holder document uploads, or retrieve the upload URLs to process your image uploads.

Note that this is not equivalent to checking the status of the KYC evaluation overall (a document may be successfully uploaded but not be sufficient for KYC to pass).

In the event your upload URLs have expired, calling this endpoint will refresh them. Similarly, in the event a previous account holder document upload has failed, you can use this endpoint to get a new upload URL for the failed image upload.

When a new document upload is generated for a failed attempt, the response will show an additional entry in the `required_document_uploads` list in a `PENDING` state for the corresponding `image_type`.

func (*AccountHolderService) New

Create an account holder and initiate the appropriate onboarding workflow. Account holders and accounts have a 1:1 relationship. When an account holder is successfully created an associated account is also created. All calls to this endpoint will return a synchronous response. The response time will depend on the workflow. In some cases, the response may indicate the workflow is under review or further action will be needed to complete the account creation process. This endpoint can only be used on accounts that are part of the program that the calling API key manages.

Note: If you choose to set a timeout for this request, we recommend 5 minutes.

func (*AccountHolderService) SimulateEnrollmentDocumentReview added in v0.41.0

func (r *AccountHolderService) SimulateEnrollmentDocumentReview(ctx context.Context, body AccountHolderSimulateEnrollmentDocumentReviewParams, opts ...option.RequestOption) (res *shared.Document, err error)

Simulates a review for an account holder document upload.

func (*AccountHolderService) SimulateEnrollmentReview added in v0.41.0

Simulates an enrollment review for an account holder. This endpoint is only applicable for workflows that may required intervention such as `KYB_BASIC`.

func (*AccountHolderService) Update

func (r *AccountHolderService) Update(ctx context.Context, accountHolderToken string, body AccountHolderUpdateParams, opts ...option.RequestOption) (res *AccountHolderUpdateResponse, err error)

Update the information associated with a particular account holder (including business owners and control persons associated to a business account). If Lithic is performing KYB or KYC and additional verification is required we will run the individual's or business's updated information again and return whether the status is accepted or pending (i.e., further action required). All calls to this endpoint will return a synchronous response. The response time will depend on the workflow. In some cases, the response may indicate the workflow is under review or further action will be needed to complete the account creation process. This endpoint can only be used on existing accounts that are part of the program that the calling API key manages.

func (*AccountHolderService) UploadDocument

func (r *AccountHolderService) UploadDocument(ctx context.Context, accountHolderToken string, body AccountHolderUploadDocumentParams, opts ...option.RequestOption) (res *shared.Document, err error)

Use this endpoint to identify which type of supported government-issued documentation you will upload for further verification. It will return two URLs to upload your document images to - one for the front image and one for the back image.

This endpoint is only valid for evaluations in a `PENDING_DOCUMENT` state.

Uploaded images must either be a `jpg` or `png` file, and each must be less than 15 MiB. Once both required uploads have been successfully completed, your document will be run through KYC verification.

If you have registered a webhook, you will receive evaluation updates for any document submission evaluations, as well as for any failed document uploads.

Two document submission attempts are permitted via this endpoint before a `REJECTED` status is returned and the account creation process is ended. Currently only one type of account holder document is supported per KYC verification.

type AccountHolderSimulateEnrollmentDocumentReviewParams added in v0.41.0

type AccountHolderSimulateEnrollmentDocumentReviewParams struct {
	// The account holder document upload which to perform the simulation upon.
	DocumentUploadToken param.Field[string] `json:"document_upload_token,required"`
	// An account holder document's upload status for use within the simulation.
	Status param.Field[AccountHolderSimulateEnrollmentDocumentReviewParamsStatus] `json:"status,required"`
	// A list of status reasons associated with a KYB account holder in PENDING_REVIEW
	AcceptedEntityStatusReasons param.Field[[]string] `json:"accepted_entity_status_reasons"`
	// Status reason that will be associated with the simulated account holder status.
	// Only required for a `REJECTED` status or `PARTIAL_APPROVAL` status.
	StatusReason param.Field[AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason] `json:"status_reason"`
}

func (AccountHolderSimulateEnrollmentDocumentReviewParams) MarshalJSON added in v0.41.0

func (r AccountHolderSimulateEnrollmentDocumentReviewParams) MarshalJSON() (data []byte, err error)

type AccountHolderSimulateEnrollmentDocumentReviewParamsStatus added in v0.41.0

type AccountHolderSimulateEnrollmentDocumentReviewParamsStatus string

An account holder document's upload status for use within the simulation.

const (
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusUploaded        AccountHolderSimulateEnrollmentDocumentReviewParamsStatus = "UPLOADED"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusAccepted        AccountHolderSimulateEnrollmentDocumentReviewParamsStatus = "ACCEPTED"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusRejected        AccountHolderSimulateEnrollmentDocumentReviewParamsStatus = "REJECTED"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusPartialApproval AccountHolderSimulateEnrollmentDocumentReviewParamsStatus = "PARTIAL_APPROVAL"
)

func (AccountHolderSimulateEnrollmentDocumentReviewParamsStatus) IsKnown added in v0.41.0

type AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason added in v0.41.0

type AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason string

Status reason that will be associated with the simulated account holder status. Only required for a `REJECTED` status or `PARTIAL_APPROVAL` status.

const (
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReasonDocumentMissingRequiredData     AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason = "DOCUMENT_MISSING_REQUIRED_DATA"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReasonDocumentUploadTooBlurry         AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason = "DOCUMENT_UPLOAD_TOO_BLURRY"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReasonFileSizeTooLarge                AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason = "FILE_SIZE_TOO_LARGE"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReasonInvalidDocumentType             AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason = "INVALID_DOCUMENT_TYPE"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReasonInvalidDocumentUpload           AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason = "INVALID_DOCUMENT_UPLOAD"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReasonInvalidEntity                   AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason = "INVALID_ENTITY"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReasonDocumentExpired                 AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason = "DOCUMENT_EXPIRED"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReasonDocumentIssuedGreaterThan30Days AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason = "DOCUMENT_ISSUED_GREATER_THAN_30_DAYS"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReasonDocumentTypeNotSupported        AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason = "DOCUMENT_TYPE_NOT_SUPPORTED"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReasonUnknownFailureReason            AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason = "UNKNOWN_FAILURE_REASON"
	AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReasonUnknownError                    AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason = "UNKNOWN_ERROR"
)

func (AccountHolderSimulateEnrollmentDocumentReviewParamsStatusReason) IsKnown added in v0.41.0

type AccountHolderSimulateEnrollmentReviewParams added in v0.41.0

type AccountHolderSimulateEnrollmentReviewParams struct {
	// The account holder which to perform the simulation upon.
	AccountHolderToken param.Field[string] `json:"account_holder_token"`
	// An account holder's status for use within the simulation.
	Status param.Field[AccountHolderSimulateEnrollmentReviewParamsStatus] `json:"status"`
	// Status reason that will be associated with the simulated account holder status.
	// Only required for a `REJECTED` status.
	StatusReasons param.Field[[]AccountHolderSimulateEnrollmentReviewParamsStatusReason] `json:"status_reasons"`
}

func (AccountHolderSimulateEnrollmentReviewParams) MarshalJSON added in v0.41.0

func (r AccountHolderSimulateEnrollmentReviewParams) MarshalJSON() (data []byte, err error)

type AccountHolderSimulateEnrollmentReviewParamsStatus added in v0.41.0

type AccountHolderSimulateEnrollmentReviewParamsStatus string

An account holder's status for use within the simulation.

const (
	AccountHolderSimulateEnrollmentReviewParamsStatusAccepted AccountHolderSimulateEnrollmentReviewParamsStatus = "ACCEPTED"
	AccountHolderSimulateEnrollmentReviewParamsStatusRejected AccountHolderSimulateEnrollmentReviewParamsStatus = "REJECTED"
)

func (AccountHolderSimulateEnrollmentReviewParamsStatus) IsKnown added in v0.41.0

type AccountHolderSimulateEnrollmentReviewParamsStatusReason added in v0.41.0

type AccountHolderSimulateEnrollmentReviewParamsStatusReason string
const (
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonPrimaryBusinessEntityIDVerificationFailure       AccountHolderSimulateEnrollmentReviewParamsStatusReason = "PRIMARY_BUSINESS_ENTITY_ID_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonPrimaryBusinessEntityAddressVerificationFailure  AccountHolderSimulateEnrollmentReviewParamsStatusReason = "PRIMARY_BUSINESS_ENTITY_ADDRESS_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonPrimaryBusinessEntityNameVerificationFailure     AccountHolderSimulateEnrollmentReviewParamsStatusReason = "PRIMARY_BUSINESS_ENTITY_NAME_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonPrimaryBusinessEntityBusinessOfficersNotMatched  AccountHolderSimulateEnrollmentReviewParamsStatusReason = "PRIMARY_BUSINESS_ENTITY_BUSINESS_OFFICERS_NOT_MATCHED"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonPrimaryBusinessEntitySosFilingInactive           AccountHolderSimulateEnrollmentReviewParamsStatusReason = "PRIMARY_BUSINESS_ENTITY_SOS_FILING_INACTIVE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonPrimaryBusinessEntitySosNotMatched               AccountHolderSimulateEnrollmentReviewParamsStatusReason = "PRIMARY_BUSINESS_ENTITY_SOS_NOT_MATCHED"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonPrimaryBusinessEntityCmraFailure                 AccountHolderSimulateEnrollmentReviewParamsStatusReason = "PRIMARY_BUSINESS_ENTITY_CMRA_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonPrimaryBusinessEntityWatchlistFailure            AccountHolderSimulateEnrollmentReviewParamsStatusReason = "PRIMARY_BUSINESS_ENTITY_WATCHLIST_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonPrimaryBusinessEntityRegisteredAgentFailure      AccountHolderSimulateEnrollmentReviewParamsStatusReason = "PRIMARY_BUSINESS_ENTITY_REGISTERED_AGENT_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonControlPersonBlocklistAlertFailure               AccountHolderSimulateEnrollmentReviewParamsStatusReason = "CONTROL_PERSON_BLOCKLIST_ALERT_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonControlPersonIDVerificationFailure               AccountHolderSimulateEnrollmentReviewParamsStatusReason = "CONTROL_PERSON_ID_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonControlPersonDobVerificationFailure              AccountHolderSimulateEnrollmentReviewParamsStatusReason = "CONTROL_PERSON_DOB_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonControlPersonNameVerificationFailure             AccountHolderSimulateEnrollmentReviewParamsStatusReason = "CONTROL_PERSON_NAME_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonBeneficialOwnerIndividualDobVerificationFailure  AccountHolderSimulateEnrollmentReviewParamsStatusReason = "BENEFICIAL_OWNER_INDIVIDUAL_DOB_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonBeneficialOwnerIndividualBlocklistAlertFailure   AccountHolderSimulateEnrollmentReviewParamsStatusReason = "BENEFICIAL_OWNER_INDIVIDUAL_BLOCKLIST_ALERT_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonBeneficialOwnerIndividualIDVerificationFailure   AccountHolderSimulateEnrollmentReviewParamsStatusReason = "BENEFICIAL_OWNER_INDIVIDUAL_ID_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewParamsStatusReasonBeneficialOwnerIndividualNameVerificationFailure AccountHolderSimulateEnrollmentReviewParamsStatusReason = "BENEFICIAL_OWNER_INDIVIDUAL_NAME_VERIFICATION_FAILURE"
)

func (AccountHolderSimulateEnrollmentReviewParamsStatusReason) IsKnown added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponse added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponse struct {
	// Globally unique identifier for the account holder.
	Token string `json:"token" format:"uuid"`
	// Globally unique identifier for the account.
	AccountToken string `json:"account_token" format:"uuid"`
	// Deprecated.
	BeneficialOwnerEntities []KYBBusinessEntity `json:"beneficial_owner_entities"`
	// Only present when user_type == "BUSINESS". You must submit a list of all direct
	// and indirect individuals with 25% or more ownership in the company. A maximum of
	// 4 beneficial owners can be submitted. If no individual owns 25% of the company
	// you do not need to send beneficial owner information. See
	// [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf)
	// (Section I) for more background on individuals that should be included.
	BeneficialOwnerIndividuals []AccountHolderSimulateEnrollmentReviewResponseBeneficialOwnerIndividual `json:"beneficial_owner_individuals"`
	// Only applicable for customers using the KYC-Exempt workflow to enroll authorized
	// users of businesses. Pass the account_token of the enrolled business associated
	// with the AUTHORIZED_USER in this field.
	BusinessAccountToken string `json:"business_account_token,nullable" format:"uuid"`
	// Only present when user_type == "BUSINESS". Information about the business for
	// which the account is being opened and KYB is being run.
	BusinessEntity KYBBusinessEntity `json:"business_entity"`
	// Only present when user_type == "BUSINESS".
	//
	// An individual with significant responsibility for managing the legal entity
	// (e.g., a Chief Executive Officer, Chief Financial Officer, Chief Operating
	// Officer,
	//
	// Managing Member, General Partner, President, Vice President, or Treasurer). This
	// can be an executive, or someone who will have program-wide access
	//
	// to the cards that Lithic will provide. In some cases, this individual could also
	// be a beneficial owner listed above.
	ControlPerson AccountHolderSimulateEnrollmentReviewResponseControlPerson `json:"control_person"`
	// Timestamp of when the account holder was created.
	Created time.Time `json:"created" format:"date-time"`
	// (Deprecated. Use control_person.email when user_type == "BUSINESS". Use
	// individual.phone_number when user_type == "INDIVIDUAL".) Primary email of
	// Account Holder.
	Email string `json:"email"`
	// The type of KYC exemption for a KYC-Exempt Account Holder. "None" if the account
	// holder is not KYC-Exempt.
	ExemptionType AccountHolderSimulateEnrollmentReviewResponseExemptionType `json:"exemption_type"`
	// Customer-provided token that indicates a relationship with an object outside of
	// the Lithic ecosystem.
	ExternalID string `json:"external_id"`
	// Only present when user_type == "INDIVIDUAL". Information about the individual
	// for which the account is being opened and KYC is being run.
	Individual AccountHolderSimulateEnrollmentReviewResponseIndividual `json:"individual"`
	// Only present when user_type == "BUSINESS". User-submitted description of the
	// business.
	NatureOfBusiness string `json:"nature_of_business"`
	// (Deprecated. Use control_person.phone_number when user_type == "BUSINESS". Use
	// individual.phone_number when user_type == "INDIVIDUAL".) Primary phone of
	// Account Holder, entered in E.164 format.
	PhoneNumber string `json:"phone_number"`
	// Only present for "KYB_BASIC" and "KYC_ADVANCED" workflows. A list of documents
	// required for the account holder to be approved.
	RequiredDocuments []RequiredDocument `json:"required_documents"`
	// (Deprecated. Use verification_application.status instead) KYC and KYB evaluation
	// states.
	//
	// Note: `PENDING_RESUBMIT` and `PENDING_DOCUMENT` are only applicable for the
	// `ADVANCED` workflow.
	Status AccountHolderSimulateEnrollmentReviewResponseStatus `json:"status"`
	// (Deprecated. Use verification_application.status_reasons) Reason for the
	// evaluation status.
	StatusReasons []AccountHolderSimulateEnrollmentReviewResponseStatusReason `json:"status_reasons"`
	// The type of Account Holder. If the type is "INDIVIDUAL", the "individual"
	// attribute will be present.
	//
	// If the type is "BUSINESS" then the "business_entity", "control_person",
	// "beneficial_owner_individuals", "nature_of_business", and "website_url"
	// attributes will be present.
	UserType AccountHolderSimulateEnrollmentReviewResponseUserType `json:"user_type"`
	// Information about the most recent identity verification attempt
	VerificationApplication AccountHolderSimulateEnrollmentReviewResponseVerificationApplication `json:"verification_application"`
	// Only present when user_type == "BUSINESS". Business's primary website.
	WebsiteURL string                                            `json:"website_url"`
	JSON       accountHolderSimulateEnrollmentReviewResponseJSON `json:"-"`
}

func (*AccountHolderSimulateEnrollmentReviewResponse) UnmarshalJSON added in v0.41.0

func (r *AccountHolderSimulateEnrollmentReviewResponse) UnmarshalJSON(data []byte) (err error)

type AccountHolderSimulateEnrollmentReviewResponseBeneficialOwnerIndividual added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseBeneficialOwnerIndividual struct {
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address AccountHolderSimulateEnrollmentReviewResponseBeneficialOwnerIndividualsAddress `json:"address"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob string `json:"dob"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email string `json:"email"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName string `json:"first_name"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName string `json:"last_name"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber string                                                                     `json:"phone_number"`
	JSON        accountHolderSimulateEnrollmentReviewResponseBeneficialOwnerIndividualJSON `json:"-"`
}

func (*AccountHolderSimulateEnrollmentReviewResponseBeneficialOwnerIndividual) UnmarshalJSON added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseBeneficialOwnerIndividualsAddress added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseBeneficialOwnerIndividualsAddress struct {
	// Valid deliverable address (no PO boxes).
	Address1 string `json:"address1,required"`
	// Name of city.
	City string `json:"city,required"`
	// Valid country code. Only USA is currently supported, entered in uppercase ISO
	// 3166-1 alpha-3 three-character format.
	Country string `json:"country,required"`
	// Valid postal code. Only USA ZIP codes are currently supported, entered as a
	// five-digit ZIP or nine-digit ZIP+4.
	PostalCode string `json:"postal_code,required"`
	// Valid state code. Only USA state codes are currently supported, entered in
	// uppercase ISO 3166-2 two-character format.
	State string `json:"state,required"`
	// Unit or apartment number (if applicable).
	Address2 string                                                                             `json:"address2"`
	JSON     accountHolderSimulateEnrollmentReviewResponseBeneficialOwnerIndividualsAddressJSON `json:"-"`
}

Individual's current address - PO boxes, UPS drops, and FedEx drops are not acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.

func (*AccountHolderSimulateEnrollmentReviewResponseBeneficialOwnerIndividualsAddress) UnmarshalJSON added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseControlPerson added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseControlPerson struct {
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address AccountHolderSimulateEnrollmentReviewResponseControlPersonAddress `json:"address"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob string `json:"dob"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email string `json:"email"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName string `json:"first_name"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName string `json:"last_name"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber string                                                         `json:"phone_number"`
	JSON        accountHolderSimulateEnrollmentReviewResponseControlPersonJSON `json:"-"`
}

Only present when user_type == "BUSINESS".

An individual with significant responsibility for managing the legal entity (e.g., a Chief Executive Officer, Chief Financial Officer, Chief Operating Officer,

Managing Member, General Partner, President, Vice President, or Treasurer). This can be an executive, or someone who will have program-wide access

to the cards that Lithic will provide. In some cases, this individual could also be a beneficial owner listed above.

func (*AccountHolderSimulateEnrollmentReviewResponseControlPerson) UnmarshalJSON added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseControlPersonAddress added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseControlPersonAddress struct {
	// Valid deliverable address (no PO boxes).
	Address1 string `json:"address1,required"`
	// Name of city.
	City string `json:"city,required"`
	// Valid country code. Only USA is currently supported, entered in uppercase ISO
	// 3166-1 alpha-3 three-character format.
	Country string `json:"country,required"`
	// Valid postal code. Only USA ZIP codes are currently supported, entered as a
	// five-digit ZIP or nine-digit ZIP+4.
	PostalCode string `json:"postal_code,required"`
	// Valid state code. Only USA state codes are currently supported, entered in
	// uppercase ISO 3166-2 two-character format.
	State string `json:"state,required"`
	// Unit or apartment number (if applicable).
	Address2 string                                                                `json:"address2"`
	JSON     accountHolderSimulateEnrollmentReviewResponseControlPersonAddressJSON `json:"-"`
}

Individual's current address - PO boxes, UPS drops, and FedEx drops are not acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.

func (*AccountHolderSimulateEnrollmentReviewResponseControlPersonAddress) UnmarshalJSON added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseExemptionType added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseExemptionType string

The type of KYC exemption for a KYC-Exempt Account Holder. "None" if the account holder is not KYC-Exempt.

const (
	AccountHolderSimulateEnrollmentReviewResponseExemptionTypeAuthorizedUser  AccountHolderSimulateEnrollmentReviewResponseExemptionType = "AUTHORIZED_USER"
	AccountHolderSimulateEnrollmentReviewResponseExemptionTypePrepaidCardUser AccountHolderSimulateEnrollmentReviewResponseExemptionType = "PREPAID_CARD_USER"
)

func (AccountHolderSimulateEnrollmentReviewResponseExemptionType) IsKnown added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseIndividual added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseIndividual struct {
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address AccountHolderSimulateEnrollmentReviewResponseIndividualAddress `json:"address"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob string `json:"dob"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email string `json:"email"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName string `json:"first_name"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName string `json:"last_name"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber string                                                      `json:"phone_number"`
	JSON        accountHolderSimulateEnrollmentReviewResponseIndividualJSON `json:"-"`
}

Only present when user_type == "INDIVIDUAL". Information about the individual for which the account is being opened and KYC is being run.

func (*AccountHolderSimulateEnrollmentReviewResponseIndividual) UnmarshalJSON added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseIndividualAddress added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseIndividualAddress struct {
	// Valid deliverable address (no PO boxes).
	Address1 string `json:"address1,required"`
	// Name of city.
	City string `json:"city,required"`
	// Valid country code. Only USA is currently supported, entered in uppercase ISO
	// 3166-1 alpha-3 three-character format.
	Country string `json:"country,required"`
	// Valid postal code. Only USA ZIP codes are currently supported, entered as a
	// five-digit ZIP or nine-digit ZIP+4.
	PostalCode string `json:"postal_code,required"`
	// Valid state code. Only USA state codes are currently supported, entered in
	// uppercase ISO 3166-2 two-character format.
	State string `json:"state,required"`
	// Unit or apartment number (if applicable).
	Address2 string                                                             `json:"address2"`
	JSON     accountHolderSimulateEnrollmentReviewResponseIndividualAddressJSON `json:"-"`
}

Individual's current address - PO boxes, UPS drops, and FedEx drops are not acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.

func (*AccountHolderSimulateEnrollmentReviewResponseIndividualAddress) UnmarshalJSON added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseStatus added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseStatus string

(Deprecated. Use verification_application.status instead) KYC and KYB evaluation states.

Note: `PENDING_RESUBMIT` and `PENDING_DOCUMENT` are only applicable for the `ADVANCED` workflow.

const (
	AccountHolderSimulateEnrollmentReviewResponseStatusAccepted        AccountHolderSimulateEnrollmentReviewResponseStatus = "ACCEPTED"
	AccountHolderSimulateEnrollmentReviewResponseStatusPendingDocument AccountHolderSimulateEnrollmentReviewResponseStatus = "PENDING_DOCUMENT"
	AccountHolderSimulateEnrollmentReviewResponseStatusPendingResubmit AccountHolderSimulateEnrollmentReviewResponseStatus = "PENDING_RESUBMIT"
	AccountHolderSimulateEnrollmentReviewResponseStatusRejected        AccountHolderSimulateEnrollmentReviewResponseStatus = "REJECTED"
)

func (AccountHolderSimulateEnrollmentReviewResponseStatus) IsKnown added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseStatusReason added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseStatusReason string

Status Reasons for KYC/KYB enrollment states

const (
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonAddressVerificationFailure                      AccountHolderSimulateEnrollmentReviewResponseStatusReason = "ADDRESS_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonAgeThresholdFailure                             AccountHolderSimulateEnrollmentReviewResponseStatusReason = "AGE_THRESHOLD_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonCompleteVerificationFailure                     AccountHolderSimulateEnrollmentReviewResponseStatusReason = "COMPLETE_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonDobVerificationFailure                          AccountHolderSimulateEnrollmentReviewResponseStatusReason = "DOB_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonIDVerificationFailure                           AccountHolderSimulateEnrollmentReviewResponseStatusReason = "ID_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonMaxDocumentAttempts                             AccountHolderSimulateEnrollmentReviewResponseStatusReason = "MAX_DOCUMENT_ATTEMPTS"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonMaxResubmissionAttempts                         AccountHolderSimulateEnrollmentReviewResponseStatusReason = "MAX_RESUBMISSION_ATTEMPTS"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonNameVerificationFailure                         AccountHolderSimulateEnrollmentReviewResponseStatusReason = "NAME_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonOtherVerificationFailure                        AccountHolderSimulateEnrollmentReviewResponseStatusReason = "OTHER_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonRiskThresholdFailure                            AccountHolderSimulateEnrollmentReviewResponseStatusReason = "RISK_THRESHOLD_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonWatchlistAlertFailure                           AccountHolderSimulateEnrollmentReviewResponseStatusReason = "WATCHLIST_ALERT_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonPrimaryBusinessEntityIDVerificationFailure      AccountHolderSimulateEnrollmentReviewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_ID_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonPrimaryBusinessEntityAddressVerificationFailure AccountHolderSimulateEnrollmentReviewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_ADDRESS_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonPrimaryBusinessEntityNameVerificationFailure    AccountHolderSimulateEnrollmentReviewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_NAME_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonPrimaryBusinessEntityBusinessOfficersNotMatched AccountHolderSimulateEnrollmentReviewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_BUSINESS_OFFICERS_NOT_MATCHED"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonPrimaryBusinessEntitySosFilingInactive          AccountHolderSimulateEnrollmentReviewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_SOS_FILING_INACTIVE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonPrimaryBusinessEntitySosNotMatched              AccountHolderSimulateEnrollmentReviewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_SOS_NOT_MATCHED"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonPrimaryBusinessEntityCmraFailure                AccountHolderSimulateEnrollmentReviewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_CMRA_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonPrimaryBusinessEntityWatchlistFailure           AccountHolderSimulateEnrollmentReviewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_WATCHLIST_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonPrimaryBusinessEntityRegisteredAgentFailure     AccountHolderSimulateEnrollmentReviewResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_REGISTERED_AGENT_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonControlPersonBlocklistAlertFailure              AccountHolderSimulateEnrollmentReviewResponseStatusReason = "CONTROL_PERSON_BLOCKLIST_ALERT_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonControlPersonIDVerificationFailure              AccountHolderSimulateEnrollmentReviewResponseStatusReason = "CONTROL_PERSON_ID_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonControlPersonDobVerificationFailure             AccountHolderSimulateEnrollmentReviewResponseStatusReason = "CONTROL_PERSON_DOB_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseStatusReasonControlPersonNameVerificationFailure            AccountHolderSimulateEnrollmentReviewResponseStatusReason = "CONTROL_PERSON_NAME_VERIFICATION_FAILURE"
)

func (AccountHolderSimulateEnrollmentReviewResponseStatusReason) IsKnown added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseUserType added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseUserType string

The type of Account Holder. If the type is "INDIVIDUAL", the "individual" attribute will be present.

If the type is "BUSINESS" then the "business_entity", "control_person", "beneficial_owner_individuals", "nature_of_business", and "website_url" attributes will be present.

const (
	AccountHolderSimulateEnrollmentReviewResponseUserTypeBusiness   AccountHolderSimulateEnrollmentReviewResponseUserType = "BUSINESS"
	AccountHolderSimulateEnrollmentReviewResponseUserTypeIndividual AccountHolderSimulateEnrollmentReviewResponseUserType = "INDIVIDUAL"
)

func (AccountHolderSimulateEnrollmentReviewResponseUserType) IsKnown added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseVerificationApplication added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseVerificationApplication struct {
	// Timestamp of when the application was created.
	Created time.Time `json:"created,required" format:"date-time"`
	// KYC and KYB evaluation states.
	//
	// Note: `PENDING_RESUBMIT` and `PENDING_DOCUMENT` are only applicable for the
	// `ADVANCED` workflow.
	Status AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatus `json:"status,required"`
	// Reason for the evaluation status.
	StatusReasons []AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason `json:"status_reasons,required"`
	// Timestamp of when the application was last updated.
	Updated time.Time `json:"updated,required" format:"date-time"`
	// Timestamp of when the application passed the verification process. Only present
	// if `status` is `ACCEPTED`
	KyPassedAt time.Time                                                                `json:"ky_passed_at" format:"date-time"`
	JSON       accountHolderSimulateEnrollmentReviewResponseVerificationApplicationJSON `json:"-"`
}

Information about the most recent identity verification attempt

func (*AccountHolderSimulateEnrollmentReviewResponseVerificationApplication) UnmarshalJSON added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatus added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatus string

KYC and KYB evaluation states.

Note: `PENDING_RESUBMIT` and `PENDING_DOCUMENT` are only applicable for the `ADVANCED` workflow.

const (
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusAccepted        AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatus = "ACCEPTED"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusPendingDocument AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatus = "PENDING_DOCUMENT"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusPendingResubmit AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatus = "PENDING_RESUBMIT"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusRejected        AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatus = "REJECTED"
)

func (AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatus) IsKnown added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason added in v0.41.0

type AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason string

Status Reasons for KYC/KYB enrollment states

const (
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonAddressVerificationFailure                      AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "ADDRESS_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonAgeThresholdFailure                             AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "AGE_THRESHOLD_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonCompleteVerificationFailure                     AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "COMPLETE_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonDobVerificationFailure                          AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "DOB_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonIDVerificationFailure                           AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "ID_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonMaxDocumentAttempts                             AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "MAX_DOCUMENT_ATTEMPTS"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonMaxResubmissionAttempts                         AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "MAX_RESUBMISSION_ATTEMPTS"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonNameVerificationFailure                         AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "NAME_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonOtherVerificationFailure                        AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "OTHER_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonRiskThresholdFailure                            AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "RISK_THRESHOLD_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonWatchlistAlertFailure                           AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "WATCHLIST_ALERT_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonPrimaryBusinessEntityIDVerificationFailure      AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_ID_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonPrimaryBusinessEntityAddressVerificationFailure AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_ADDRESS_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonPrimaryBusinessEntityNameVerificationFailure    AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_NAME_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonPrimaryBusinessEntityBusinessOfficersNotMatched AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_BUSINESS_OFFICERS_NOT_MATCHED"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonPrimaryBusinessEntitySosFilingInactive          AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_SOS_FILING_INACTIVE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonPrimaryBusinessEntitySosNotMatched              AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_SOS_NOT_MATCHED"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonPrimaryBusinessEntityCmraFailure                AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_CMRA_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonPrimaryBusinessEntityWatchlistFailure           AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_WATCHLIST_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonPrimaryBusinessEntityRegisteredAgentFailure     AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_REGISTERED_AGENT_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonControlPersonBlocklistAlertFailure              AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "CONTROL_PERSON_BLOCKLIST_ALERT_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonControlPersonIDVerificationFailure              AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "CONTROL_PERSON_ID_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonControlPersonDobVerificationFailure             AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "CONTROL_PERSON_DOB_VERIFICATION_FAILURE"
	AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReasonControlPersonNameVerificationFailure            AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason = "CONTROL_PERSON_NAME_VERIFICATION_FAILURE"
)

func (AccountHolderSimulateEnrollmentReviewResponseVerificationApplicationStatusReason) IsKnown added in v0.41.0

type AccountHolderStatus

type AccountHolderStatus string

(Deprecated. Use verification_application.status instead)

KYC and KYB evaluation states.

Note:

- `PENDING_REVIEW` is only applicable for the `KYB_BASIC` workflow.

const (
	AccountHolderStatusAccepted        AccountHolderStatus = "ACCEPTED"
	AccountHolderStatusPendingReview   AccountHolderStatus = "PENDING_REVIEW"
	AccountHolderStatusPendingDocument AccountHolderStatus = "PENDING_DOCUMENT"
	AccountHolderStatusPendingResubmit AccountHolderStatus = "PENDING_RESUBMIT"
	AccountHolderStatusRejected        AccountHolderStatus = "REJECTED"
)

func (AccountHolderStatus) IsKnown added in v0.27.0

func (r AccountHolderStatus) IsKnown() bool

type AccountHolderStatusReason added in v0.5.0

type AccountHolderStatusReason string
const (
	AccountHolderStatusReasonAddressVerificationFailure  AccountHolderStatusReason = "ADDRESS_VERIFICATION_FAILURE"
	AccountHolderStatusReasonAgeThresholdFailure         AccountHolderStatusReason = "AGE_THRESHOLD_FAILURE"
	AccountHolderStatusReasonCompleteVerificationFailure AccountHolderStatusReason = "COMPLETE_VERIFICATION_FAILURE"
	AccountHolderStatusReasonDobVerificationFailure      AccountHolderStatusReason = "DOB_VERIFICATION_FAILURE"
	AccountHolderStatusReasonIDVerificationFailure       AccountHolderStatusReason = "ID_VERIFICATION_FAILURE"
	AccountHolderStatusReasonMaxDocumentAttempts         AccountHolderStatusReason = "MAX_DOCUMENT_ATTEMPTS"
	AccountHolderStatusReasonMaxResubmissionAttempts     AccountHolderStatusReason = "MAX_RESUBMISSION_ATTEMPTS"
	AccountHolderStatusReasonNameVerificationFailure     AccountHolderStatusReason = "NAME_VERIFICATION_FAILURE"
	AccountHolderStatusReasonOtherVerificationFailure    AccountHolderStatusReason = "OTHER_VERIFICATION_FAILURE"
	AccountHolderStatusReasonRiskThresholdFailure        AccountHolderStatusReason = "RISK_THRESHOLD_FAILURE"
	AccountHolderStatusReasonWatchlistAlertFailure       AccountHolderStatusReason = "WATCHLIST_ALERT_FAILURE"
)

func (AccountHolderStatusReason) IsKnown added in v0.27.0

func (r AccountHolderStatusReason) IsKnown() bool

type AccountHolderUpdateParams

type AccountHolderUpdateParams struct {
	// The KYB request payload for updating a business.
	Body AccountHolderUpdateParamsBodyUnion `json:"body,required"`
}

func (AccountHolderUpdateParams) MarshalJSON

func (r AccountHolderUpdateParams) MarshalJSON() (data []byte, err error)

type AccountHolderUpdateParamsBody added in v0.68.0

type AccountHolderUpdateParamsBody struct {
	// Allowed for: KYC-Exempt, BYO-KYC, BYO-KYB.
	Address                    param.Field[AddressUpdateParam] `json:"address"`
	BeneficialOwnerEntities    param.Field[interface{}]        `json:"beneficial_owner_entities"`
	BeneficialOwnerIndividuals param.Field[interface{}]        `json:"beneficial_owner_individuals"`
	// Allowed for: KYC-Exempt, BYO-KYC. The token of the business account to which the
	// account holder is associated.
	BusinessAccountToken param.Field[string]      `json:"business_account_token"`
	BusinessEntity       param.Field[interface{}] `json:"business_entity"`
	ControlPerson        param.Field[interface{}] `json:"control_person"`
	// Allowed for all Account Holders. Account holder's email address. The primary
	// purpose of this field is for cardholder identification and verification during
	// the digital wallet tokenization process.
	Email param.Field[string] `json:"email"`
	// A user provided id that can be used to link an account holder with an external
	// system
	ExternalID param.Field[string] `json:"external_id"`
	// Allowed for KYC-Exempt, BYO-KYC. Account holder's first name.
	FirstName  param.Field[string]      `json:"first_name"`
	Individual param.Field[interface{}] `json:"individual"`
	// Allowed for KYC-Exempt, BYO-KYC. Account holder's last name.
	LastName param.Field[string] `json:"last_name"`
	// Allowed for BYO-KYB. Legal business name of the account holder.
	LegalBusinessName param.Field[string] `json:"legal_business_name"`
	// Short description of the company's line of business (i.e., what does the company
	// do?).
	NatureOfBusiness param.Field[string] `json:"nature_of_business"`
	// Allowed for all Account Holders. Account holder's phone number, entered in E.164
	// format. The primary purpose of this field is for cardholder identification and
	// verification during the digital wallet tokenization process.
	PhoneNumber param.Field[string] `json:"phone_number"`
	// Company website URL.
	WebsiteURL param.Field[string] `json:"website_url"`
}

The KYB request payload for updating a business.

func (AccountHolderUpdateParamsBody) MarshalJSON added in v0.68.0

func (r AccountHolderUpdateParamsBody) MarshalJSON() (data []byte, err error)

type AccountHolderUpdateParamsBodyKYBPatchRequest added in v0.68.0

type AccountHolderUpdateParamsBodyKYBPatchRequest struct {
	// Deprecated.
	//
	// Deprecated: deprecated
	BeneficialOwnerEntities param.Field[[]AccountHolderUpdateParamsBodyKYBPatchRequestBeneficialOwnerEntity] `json:"beneficial_owner_entities"`
	// You must submit a list of all direct and indirect individuals with 25% or more
	// ownership in the company. A maximum of 4 beneficial owners can be submitted. If
	// no individual owns 25% of the company you do not need to send beneficial owner
	// information. See
	// [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf)
	// (Section I) for more background on individuals that should be included.
	BeneficialOwnerIndividuals param.Field[[]AccountHolderUpdateParamsBodyKYBPatchRequestBeneficialOwnerIndividual] `json:"beneficial_owner_individuals"`
	// Information for business for which the account is being opened and KYB is being
	// run.
	BusinessEntity param.Field[AccountHolderUpdateParamsBodyKYBPatchRequestBusinessEntity] `json:"business_entity"`
	// An individual with significant responsibility for managing the legal entity
	// (e.g., a Chief Executive Officer, Chief Financial Officer, Chief Operating
	// Officer, Managing Member, General Partner, President, Vice President, or
	// Treasurer). This can be an executive, or someone who will have program-wide
	// access to the cards that Lithic will provide. In some cases, this individual
	// could also be a beneficial owner listed above. See
	// [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf)
	// (Section II) for more background.
	ControlPerson param.Field[AccountHolderUpdateParamsBodyKYBPatchRequestControlPerson] `json:"control_person"`
	// A user provided id that can be used to link an account holder with an external
	// system
	ExternalID param.Field[string] `json:"external_id"`
	// Short description of the company's line of business (i.e., what does the company
	// do?).
	NatureOfBusiness param.Field[string] `json:"nature_of_business"`
	// Company website URL.
	WebsiteURL param.Field[string] `json:"website_url"`
}

The KYB request payload for updating a business.

func (AccountHolderUpdateParamsBodyKYBPatchRequest) MarshalJSON added in v0.68.0

func (r AccountHolderUpdateParamsBodyKYBPatchRequest) MarshalJSON() (data []byte, err error)

type AccountHolderUpdateParamsBodyKYBPatchRequestBeneficialOwnerEntity added in v0.68.0

type AccountHolderUpdateParamsBodyKYBPatchRequestBeneficialOwnerEntity struct {
	// Globally unique identifier for an entity.
	EntityToken param.Field[string] `json:"entity_token,required" format:"uuid"`
	// Business”s physical address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable.
	Address param.Field[AddressUpdateParam] `json:"address"`
	// Any name that the business operates under that is not its legal business name
	// (if applicable).
	DbaBusinessName param.Field[string] `json:"dba_business_name"`
	// Government-issued identification number. US Federal Employer Identification
	// Numbers (EIN) are currently supported, entered as full nine-digits, with or
	// without hyphens.
	GovernmentID param.Field[string] `json:"government_id"`
	// Legal (formal) business name.
	LegalBusinessName param.Field[string] `json:"legal_business_name"`
	// Parent company name (if applicable).
	ParentCompany param.Field[string] `json:"parent_company"`
	// One or more of the business's phone number(s), entered as a list in E.164
	// format.
	PhoneNumbers param.Field[[]string] `json:"phone_numbers"`
}

func (AccountHolderUpdateParamsBodyKYBPatchRequestBeneficialOwnerEntity) MarshalJSON added in v0.68.0

type AccountHolderUpdateParamsBodyKYBPatchRequestBeneficialOwnerIndividual added in v0.68.0

type AccountHolderUpdateParamsBodyKYBPatchRequestBeneficialOwnerIndividual struct {
	// Globally unique identifier for an entity.
	EntityToken param.Field[string] `json:"entity_token,required" format:"uuid"`
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address param.Field[AddressUpdateParam] `json:"address"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob param.Field[string] `json:"dob"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email param.Field[string] `json:"email"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName param.Field[string] `json:"first_name"`
	// Government-issued identification number (required for identity verification and
	// compliance with banking regulations). Social Security Numbers (SSN) and
	// Individual Taxpayer Identification Numbers (ITIN) are currently supported,
	// entered as full nine-digits, with or without hyphens
	GovernmentID param.Field[string] `json:"government_id"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName param.Field[string] `json:"last_name"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber param.Field[string] `json:"phone_number"`
}

Individuals associated with a KYB application. Phone number is optional.

func (AccountHolderUpdateParamsBodyKYBPatchRequestBeneficialOwnerIndividual) MarshalJSON added in v0.68.0

type AccountHolderUpdateParamsBodyKYBPatchRequestBusinessEntity added in v0.68.0

type AccountHolderUpdateParamsBodyKYBPatchRequestBusinessEntity struct {
	// Globally unique identifier for an entity.
	EntityToken param.Field[string] `json:"entity_token,required" format:"uuid"`
	// Business”s physical address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable.
	Address param.Field[AddressUpdateParam] `json:"address"`
	// Any name that the business operates under that is not its legal business name
	// (if applicable).
	DbaBusinessName param.Field[string] `json:"dba_business_name"`
	// Government-issued identification number. US Federal Employer Identification
	// Numbers (EIN) are currently supported, entered as full nine-digits, with or
	// without hyphens.
	GovernmentID param.Field[string] `json:"government_id"`
	// Legal (formal) business name.
	LegalBusinessName param.Field[string] `json:"legal_business_name"`
	// Parent company name (if applicable).
	ParentCompany param.Field[string] `json:"parent_company"`
	// One or more of the business's phone number(s), entered as a list in E.164
	// format.
	PhoneNumbers param.Field[[]string] `json:"phone_numbers"`
}

Information for business for which the account is being opened and KYB is being run.

func (AccountHolderUpdateParamsBodyKYBPatchRequestBusinessEntity) MarshalJSON added in v0.68.0

type AccountHolderUpdateParamsBodyKYBPatchRequestControlPerson added in v0.68.0

type AccountHolderUpdateParamsBodyKYBPatchRequestControlPerson struct {
	// Globally unique identifier for an entity.
	EntityToken param.Field[string] `json:"entity_token,required" format:"uuid"`
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address param.Field[AddressUpdateParam] `json:"address"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob param.Field[string] `json:"dob"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email param.Field[string] `json:"email"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName param.Field[string] `json:"first_name"`
	// Government-issued identification number (required for identity verification and
	// compliance with banking regulations). Social Security Numbers (SSN) and
	// Individual Taxpayer Identification Numbers (ITIN) are currently supported,
	// entered as full nine-digits, with or without hyphens
	GovernmentID param.Field[string] `json:"government_id"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName param.Field[string] `json:"last_name"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber param.Field[string] `json:"phone_number"`
}

An individual with significant responsibility for managing the legal entity (e.g., a Chief Executive Officer, Chief Financial Officer, Chief Operating Officer, Managing Member, General Partner, President, Vice President, or Treasurer). This can be an executive, or someone who will have program-wide access to the cards that Lithic will provide. In some cases, this individual could also be a beneficial owner listed above. See [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf) (Section II) for more background.

func (AccountHolderUpdateParamsBodyKYBPatchRequestControlPerson) MarshalJSON added in v0.68.0

type AccountHolderUpdateParamsBodyKYCPatchRequest added in v0.68.0

type AccountHolderUpdateParamsBodyKYCPatchRequest struct {
	// A user provided id that can be used to link an account holder with an external
	// system
	ExternalID param.Field[string] `json:"external_id"`
	// Information on the individual for whom the account is being opened and KYC is
	// being run.
	Individual param.Field[AccountHolderUpdateParamsBodyKYCPatchRequestIndividual] `json:"individual"`
}

The KYC request payload for updating an account holder.

func (AccountHolderUpdateParamsBodyKYCPatchRequest) MarshalJSON added in v0.68.0

func (r AccountHolderUpdateParamsBodyKYCPatchRequest) MarshalJSON() (data []byte, err error)

type AccountHolderUpdateParamsBodyKYCPatchRequestIndividual added in v0.68.0

type AccountHolderUpdateParamsBodyKYCPatchRequestIndividual struct {
	// Globally unique identifier for an entity.
	EntityToken param.Field[string] `json:"entity_token,required" format:"uuid"`
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address param.Field[AddressUpdateParam] `json:"address"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob param.Field[string] `json:"dob"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email param.Field[string] `json:"email"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName param.Field[string] `json:"first_name"`
	// Government-issued identification number (required for identity verification and
	// compliance with banking regulations). Social Security Numbers (SSN) and
	// Individual Taxpayer Identification Numbers (ITIN) are currently supported,
	// entered as full nine-digits, with or without hyphens
	GovernmentID param.Field[string] `json:"government_id"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName param.Field[string] `json:"last_name"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber param.Field[string] `json:"phone_number"`
}

Information on the individual for whom the account is being opened and KYC is being run.

func (AccountHolderUpdateParamsBodyKYCPatchRequestIndividual) MarshalJSON added in v0.68.0

type AccountHolderUpdateParamsBodyPatchRequest added in v0.68.0

type AccountHolderUpdateParamsBodyPatchRequest struct {
	// Allowed for: KYC-Exempt, BYO-KYC, BYO-KYB.
	Address param.Field[AddressUpdateParam] `json:"address"`
	// Allowed for: KYC-Exempt, BYO-KYC. The token of the business account to which the
	// account holder is associated.
	BusinessAccountToken param.Field[string] `json:"business_account_token"`
	// Allowed for all Account Holders. Account holder's email address. The primary
	// purpose of this field is for cardholder identification and verification during
	// the digital wallet tokenization process.
	Email param.Field[string] `json:"email"`
	// Allowed for KYC-Exempt, BYO-KYC. Account holder's first name.
	FirstName param.Field[string] `json:"first_name"`
	// Allowed for KYC-Exempt, BYO-KYC. Account holder's last name.
	LastName param.Field[string] `json:"last_name"`
	// Allowed for BYO-KYB. Legal business name of the account holder.
	LegalBusinessName param.Field[string] `json:"legal_business_name"`
	// Allowed for all Account Holders. Account holder's phone number, entered in E.164
	// format. The primary purpose of this field is for cardholder identification and
	// verification during the digital wallet tokenization process.
	PhoneNumber param.Field[string] `json:"phone_number"`
}

The legacy request for updating an account holder.

func (AccountHolderUpdateParamsBodyPatchRequest) MarshalJSON added in v0.68.0

func (r AccountHolderUpdateParamsBodyPatchRequest) MarshalJSON() (data []byte, err error)

type AccountHolderUpdateParamsBodyUnion added in v0.68.0

type AccountHolderUpdateParamsBodyUnion interface {
	// contains filtered or unexported methods
}

The KYB request payload for updating a business.

Satisfied by AccountHolderUpdateParamsBodyKYBPatchRequest, AccountHolderUpdateParamsBodyKYCPatchRequest, AccountHolderUpdateParamsBodyPatchRequest, AccountHolderUpdateParamsBody.

type AccountHolderUpdateResponse

type AccountHolderUpdateResponse struct {
	// Globally unique identifier for the account holder.
	Token string `json:"token" format:"uuid"`
	// Globally unique identifier for the account.
	AccountToken string `json:"account_token" format:"uuid"`
	// This field can have the runtime type of
	// [AccountHolderUpdateResponsePatchResponseAddress].
	Address interface{} `json:"address"`
	// This field can have the runtime type of [[]KYBBusinessEntity].
	BeneficialOwnerEntities interface{} `json:"beneficial_owner_entities"`
	// This field can have the runtime type of
	// [[]AccountHolderUpdateResponseKybkycPatchResponseBeneficialOwnerIndividual].
	BeneficialOwnerIndividuals interface{} `json:"beneficial_owner_individuals"`
	// Only applicable for customers using the KYC-Exempt workflow to enroll authorized
	// users of businesses. Pass the account_token of the enrolled business associated
	// with the AUTHORIZED_USER in this field.
	BusinessAccountToken string `json:"business_account_token,nullable" format:"uuid"`
	// Only present when user_type == "BUSINESS". Information about the business for
	// which the account is being opened and KYB is being run.
	BusinessEntity KYBBusinessEntity `json:"business_entity"`
	// This field can have the runtime type of
	// [AccountHolderUpdateResponseKYBKYCPatchResponseControlPerson].
	ControlPerson interface{} `json:"control_person"`
	// Timestamp of when the account holder was created.
	Created time.Time `json:"created" format:"date-time"`
	// (Deprecated. Use control_person.email when user_type == "BUSINESS". Use
	// individual.phone_number when user_type == "INDIVIDUAL".) Primary email of
	// Account Holder.
	Email string `json:"email"`
	// The type of KYC exemption for a KYC-Exempt Account Holder. "None" if the account
	// holder is not KYC-Exempt.
	ExemptionType AccountHolderUpdateResponseExemptionType `json:"exemption_type"`
	// Customer-provided token that indicates a relationship with an object outside of
	// the Lithic ecosystem.
	ExternalID string `json:"external_id"`
	// The first name for the account holder
	FirstName string `json:"first_name"`
	// This field can have the runtime type of
	// [AccountHolderUpdateResponseKYBKYCPatchResponseIndividual].
	Individual interface{} `json:"individual"`
	// The last name for the account holder
	LastName string `json:"last_name"`
	// The legal business name for the account holder
	LegalBusinessName string `json:"legal_business_name"`
	// Only present when user_type == "BUSINESS". User-submitted description of the
	// business.
	NatureOfBusiness string `json:"nature_of_business"`
	// (Deprecated. Use control_person.phone_number when user_type == "BUSINESS". Use
	// individual.phone_number when user_type == "INDIVIDUAL".) Primary phone of
	// Account Holder, entered in E.164 format.
	PhoneNumber string `json:"phone_number"`
	// This field can have the runtime type of [[]RequiredDocument].
	RequiredDocuments interface{} `json:"required_documents"`
	// (Deprecated. Use verification_application.status instead) KYC and KYB evaluation
	// states.
	//
	// Note: `PENDING_RESUBMIT` and `PENDING_DOCUMENT` are only applicable for the
	// `ADVANCED` workflow.
	Status AccountHolderUpdateResponseStatus `json:"status"`
	// This field can have the runtime type of
	// [[]AccountHolderUpdateResponseKybkycPatchResponseStatusReason].
	StatusReasons interface{} `json:"status_reasons"`
	// The type of Account Holder. If the type is "INDIVIDUAL", the "individual"
	// attribute will be present.
	//
	// If the type is "BUSINESS" then the "business_entity", "control_person",
	// "beneficial_owner_individuals", "nature_of_business", and "website_url"
	// attributes will be present.
	UserType AccountHolderUpdateResponseUserType `json:"user_type"`
	// This field can have the runtime type of
	// [AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplication].
	VerificationApplication interface{} `json:"verification_application"`
	// Only present when user_type == "BUSINESS". Business's primary website.
	WebsiteURL string                          `json:"website_url"`
	JSON       accountHolderUpdateResponseJSON `json:"-"`
	// contains filtered or unexported fields
}

func (AccountHolderUpdateResponse) AsUnion added in v0.68.0

AsUnion returns a AccountHolderUpdateResponseUnion interface which you can cast to the specific types for more type safety.

Possible runtime types of the union are AccountHolderUpdateResponseKYBKYCPatchResponse, AccountHolderUpdateResponsePatchResponse.

func (*AccountHolderUpdateResponse) UnmarshalJSON

func (r *AccountHolderUpdateResponse) UnmarshalJSON(data []byte) (err error)

type AccountHolderUpdateResponseExemptionType added in v0.68.0

type AccountHolderUpdateResponseExemptionType string

The type of KYC exemption for a KYC-Exempt Account Holder. "None" if the account holder is not KYC-Exempt.

const (
	AccountHolderUpdateResponseExemptionTypeAuthorizedUser  AccountHolderUpdateResponseExemptionType = "AUTHORIZED_USER"
	AccountHolderUpdateResponseExemptionTypePrepaidCardUser AccountHolderUpdateResponseExemptionType = "PREPAID_CARD_USER"
)

func (AccountHolderUpdateResponseExemptionType) IsKnown added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponse added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponse struct {
	// Globally unique identifier for the account holder.
	Token string `json:"token" format:"uuid"`
	// Globally unique identifier for the account.
	AccountToken string `json:"account_token" format:"uuid"`
	// Deprecated.
	BeneficialOwnerEntities []KYBBusinessEntity `json:"beneficial_owner_entities"`
	// Only present when user_type == "BUSINESS". You must submit a list of all direct
	// and indirect individuals with 25% or more ownership in the company. A maximum of
	// 4 beneficial owners can be submitted. If no individual owns 25% of the company
	// you do not need to send beneficial owner information. See
	// [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf)
	// (Section I) for more background on individuals that should be included.
	BeneficialOwnerIndividuals []AccountHolderUpdateResponseKybkycPatchResponseBeneficialOwnerIndividual `json:"beneficial_owner_individuals"`
	// Only applicable for customers using the KYC-Exempt workflow to enroll authorized
	// users of businesses. Pass the account_token of the enrolled business associated
	// with the AUTHORIZED_USER in this field.
	BusinessAccountToken string `json:"business_account_token,nullable" format:"uuid"`
	// Only present when user_type == "BUSINESS". Information about the business for
	// which the account is being opened and KYB is being run.
	BusinessEntity KYBBusinessEntity `json:"business_entity"`
	// Only present when user_type == "BUSINESS".
	//
	// An individual with significant responsibility for managing the legal entity
	// (e.g., a Chief Executive Officer, Chief Financial Officer, Chief Operating
	// Officer,
	//
	// Managing Member, General Partner, President, Vice President, or Treasurer). This
	// can be an executive, or someone who will have program-wide access
	//
	// to the cards that Lithic will provide. In some cases, this individual could also
	// be a beneficial owner listed above.
	ControlPerson AccountHolderUpdateResponseKYBKYCPatchResponseControlPerson `json:"control_person"`
	// Timestamp of when the account holder was created.
	Created time.Time `json:"created" format:"date-time"`
	// (Deprecated. Use control_person.email when user_type == "BUSINESS". Use
	// individual.phone_number when user_type == "INDIVIDUAL".) Primary email of
	// Account Holder.
	Email string `json:"email"`
	// The type of KYC exemption for a KYC-Exempt Account Holder. "None" if the account
	// holder is not KYC-Exempt.
	ExemptionType AccountHolderUpdateResponseKYBKYCPatchResponseExemptionType `json:"exemption_type"`
	// Customer-provided token that indicates a relationship with an object outside of
	// the Lithic ecosystem.
	ExternalID string `json:"external_id"`
	// Only present when user_type == "INDIVIDUAL". Information about the individual
	// for which the account is being opened and KYC is being run.
	Individual AccountHolderUpdateResponseKYBKYCPatchResponseIndividual `json:"individual"`
	// Only present when user_type == "BUSINESS". User-submitted description of the
	// business.
	NatureOfBusiness string `json:"nature_of_business"`
	// (Deprecated. Use control_person.phone_number when user_type == "BUSINESS". Use
	// individual.phone_number when user_type == "INDIVIDUAL".) Primary phone of
	// Account Holder, entered in E.164 format.
	PhoneNumber string `json:"phone_number"`
	// Only present for "KYB_BASIC" and "KYC_ADVANCED" workflows. A list of documents
	// required for the account holder to be approved.
	RequiredDocuments []RequiredDocument `json:"required_documents"`
	// (Deprecated. Use verification_application.status instead) KYC and KYB evaluation
	// states.
	//
	// Note: `PENDING_RESUBMIT` and `PENDING_DOCUMENT` are only applicable for the
	// `ADVANCED` workflow.
	Status AccountHolderUpdateResponseKYBKYCPatchResponseStatus `json:"status"`
	// (Deprecated. Use verification_application.status_reasons) Reason for the
	// evaluation status.
	StatusReasons []AccountHolderUpdateResponseKybkycPatchResponseStatusReason `json:"status_reasons"`
	// The type of Account Holder. If the type is "INDIVIDUAL", the "individual"
	// attribute will be present.
	//
	// If the type is "BUSINESS" then the "business_entity", "control_person",
	// "beneficial_owner_individuals", "nature_of_business", and "website_url"
	// attributes will be present.
	UserType AccountHolderUpdateResponseKYBKYCPatchResponseUserType `json:"user_type"`
	// Information about the most recent identity verification attempt
	VerificationApplication AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplication `json:"verification_application"`
	// Only present when user_type == "BUSINESS". Business's primary website.
	WebsiteURL string                                             `json:"website_url"`
	JSON       accountHolderUpdateResponseKybkycPatchResponseJSON `json:"-"`
}

func (*AccountHolderUpdateResponseKYBKYCPatchResponse) UnmarshalJSON added in v0.68.0

func (r *AccountHolderUpdateResponseKYBKYCPatchResponse) UnmarshalJSON(data []byte) (err error)

type AccountHolderUpdateResponseKYBKYCPatchResponseBeneficialOwnerIndividualsAddress added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseBeneficialOwnerIndividualsAddress struct {
	// Valid deliverable address (no PO boxes).
	Address1 string `json:"address1,required"`
	// Name of city.
	City string `json:"city,required"`
	// Valid country code. Only USA is currently supported, entered in uppercase ISO
	// 3166-1 alpha-3 three-character format.
	Country string `json:"country,required"`
	// Valid postal code. Only USA ZIP codes are currently supported, entered as a
	// five-digit ZIP or nine-digit ZIP+4.
	PostalCode string `json:"postal_code,required"`
	// Valid state code. Only USA state codes are currently supported, entered in
	// uppercase ISO 3166-2 two-character format.
	State string `json:"state,required"`
	// Unit or apartment number (if applicable).
	Address2 string                                                                              `json:"address2"`
	JSON     accountHolderUpdateResponseKybkycPatchResponseBeneficialOwnerIndividualsAddressJSON `json:"-"`
}

Individual's current address - PO boxes, UPS drops, and FedEx drops are not acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.

func (*AccountHolderUpdateResponseKYBKYCPatchResponseBeneficialOwnerIndividualsAddress) UnmarshalJSON added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseControlPerson added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseControlPerson struct {
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address AccountHolderUpdateResponseKYBKYCPatchResponseControlPersonAddress `json:"address"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob string `json:"dob"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email string `json:"email"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName string `json:"first_name"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName string `json:"last_name"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber string                                                          `json:"phone_number"`
	JSON        accountHolderUpdateResponseKybkycPatchResponseControlPersonJSON `json:"-"`
}

Only present when user_type == "BUSINESS".

An individual with significant responsibility for managing the legal entity (e.g., a Chief Executive Officer, Chief Financial Officer, Chief Operating Officer,

Managing Member, General Partner, President, Vice President, or Treasurer). This can be an executive, or someone who will have program-wide access

to the cards that Lithic will provide. In some cases, this individual could also be a beneficial owner listed above.

func (*AccountHolderUpdateResponseKYBKYCPatchResponseControlPerson) UnmarshalJSON added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseControlPersonAddress added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseControlPersonAddress struct {
	// Valid deliverable address (no PO boxes).
	Address1 string `json:"address1,required"`
	// Name of city.
	City string `json:"city,required"`
	// Valid country code. Only USA is currently supported, entered in uppercase ISO
	// 3166-1 alpha-3 three-character format.
	Country string `json:"country,required"`
	// Valid postal code. Only USA ZIP codes are currently supported, entered as a
	// five-digit ZIP or nine-digit ZIP+4.
	PostalCode string `json:"postal_code,required"`
	// Valid state code. Only USA state codes are currently supported, entered in
	// uppercase ISO 3166-2 two-character format.
	State string `json:"state,required"`
	// Unit or apartment number (if applicable).
	Address2 string                                                                 `json:"address2"`
	JSON     accountHolderUpdateResponseKybkycPatchResponseControlPersonAddressJSON `json:"-"`
}

Individual's current address - PO boxes, UPS drops, and FedEx drops are not acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.

func (*AccountHolderUpdateResponseKYBKYCPatchResponseControlPersonAddress) UnmarshalJSON added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseExemptionType added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseExemptionType string

The type of KYC exemption for a KYC-Exempt Account Holder. "None" if the account holder is not KYC-Exempt.

const (
	AccountHolderUpdateResponseKYBKYCPatchResponseExemptionTypeAuthorizedUser  AccountHolderUpdateResponseKYBKYCPatchResponseExemptionType = "AUTHORIZED_USER"
	AccountHolderUpdateResponseKYBKYCPatchResponseExemptionTypePrepaidCardUser AccountHolderUpdateResponseKYBKYCPatchResponseExemptionType = "PREPAID_CARD_USER"
)

func (AccountHolderUpdateResponseKYBKYCPatchResponseExemptionType) IsKnown added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseIndividual added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseIndividual struct {
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address AccountHolderUpdateResponseKYBKYCPatchResponseIndividualAddress `json:"address"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob string `json:"dob"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email string `json:"email"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName string `json:"first_name"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName string `json:"last_name"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber string                                                       `json:"phone_number"`
	JSON        accountHolderUpdateResponseKybkycPatchResponseIndividualJSON `json:"-"`
}

Only present when user_type == "INDIVIDUAL". Information about the individual for which the account is being opened and KYC is being run.

func (*AccountHolderUpdateResponseKYBKYCPatchResponseIndividual) UnmarshalJSON added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseIndividualAddress added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseIndividualAddress struct {
	// Valid deliverable address (no PO boxes).
	Address1 string `json:"address1,required"`
	// Name of city.
	City string `json:"city,required"`
	// Valid country code. Only USA is currently supported, entered in uppercase ISO
	// 3166-1 alpha-3 three-character format.
	Country string `json:"country,required"`
	// Valid postal code. Only USA ZIP codes are currently supported, entered as a
	// five-digit ZIP or nine-digit ZIP+4.
	PostalCode string `json:"postal_code,required"`
	// Valid state code. Only USA state codes are currently supported, entered in
	// uppercase ISO 3166-2 two-character format.
	State string `json:"state,required"`
	// Unit or apartment number (if applicable).
	Address2 string                                                              `json:"address2"`
	JSON     accountHolderUpdateResponseKybkycPatchResponseIndividualAddressJSON `json:"-"`
}

Individual's current address - PO boxes, UPS drops, and FedEx drops are not acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.

func (*AccountHolderUpdateResponseKYBKYCPatchResponseIndividualAddress) UnmarshalJSON added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseStatus added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseStatus string

(Deprecated. Use verification_application.status instead) KYC and KYB evaluation states.

Note: `PENDING_RESUBMIT` and `PENDING_DOCUMENT` are only applicable for the `ADVANCED` workflow.

const (
	AccountHolderUpdateResponseKYBKYCPatchResponseStatusAccepted        AccountHolderUpdateResponseKYBKYCPatchResponseStatus = "ACCEPTED"
	AccountHolderUpdateResponseKYBKYCPatchResponseStatusPendingDocument AccountHolderUpdateResponseKYBKYCPatchResponseStatus = "PENDING_DOCUMENT"
	AccountHolderUpdateResponseKYBKYCPatchResponseStatusPendingResubmit AccountHolderUpdateResponseKYBKYCPatchResponseStatus = "PENDING_RESUBMIT"
	AccountHolderUpdateResponseKYBKYCPatchResponseStatusRejected        AccountHolderUpdateResponseKYBKYCPatchResponseStatus = "REJECTED"
)

func (AccountHolderUpdateResponseKYBKYCPatchResponseStatus) IsKnown added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseUserType added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseUserType string

The type of Account Holder. If the type is "INDIVIDUAL", the "individual" attribute will be present.

If the type is "BUSINESS" then the "business_entity", "control_person", "beneficial_owner_individuals", "nature_of_business", and "website_url" attributes will be present.

const (
	AccountHolderUpdateResponseKYBKYCPatchResponseUserTypeBusiness   AccountHolderUpdateResponseKYBKYCPatchResponseUserType = "BUSINESS"
	AccountHolderUpdateResponseKYBKYCPatchResponseUserTypeIndividual AccountHolderUpdateResponseKYBKYCPatchResponseUserType = "INDIVIDUAL"
)

func (AccountHolderUpdateResponseKYBKYCPatchResponseUserType) IsKnown added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplication added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplication struct {
	// Timestamp of when the application was created.
	Created time.Time `json:"created,required" format:"date-time"`
	// KYC and KYB evaluation states.
	//
	// Note: `PENDING_RESUBMIT` and `PENDING_DOCUMENT` are only applicable for the
	// `ADVANCED` workflow.
	Status AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplicationStatus `json:"status,required"`
	// Reason for the evaluation status.
	StatusReasons []AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason `json:"status_reasons,required"`
	// Timestamp of when the application was last updated.
	Updated time.Time `json:"updated,required" format:"date-time"`
	// Timestamp of when the application passed the verification process. Only present
	// if `status` is `ACCEPTED`
	KyPassedAt time.Time                                                                 `json:"ky_passed_at" format:"date-time"`
	JSON       accountHolderUpdateResponseKybkycPatchResponseVerificationApplicationJSON `json:"-"`
}

Information about the most recent identity verification attempt

func (*AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplication) UnmarshalJSON added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplicationStatus added in v0.68.0

type AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplicationStatus string

KYC and KYB evaluation states.

Note: `PENDING_RESUBMIT` and `PENDING_DOCUMENT` are only applicable for the `ADVANCED` workflow.

const (
	AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplicationStatusAccepted        AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplicationStatus = "ACCEPTED"
	AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplicationStatusPendingDocument AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplicationStatus = "PENDING_DOCUMENT"
	AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplicationStatusPendingResubmit AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplicationStatus = "PENDING_RESUBMIT"
	AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplicationStatusRejected        AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplicationStatus = "REJECTED"
)

func (AccountHolderUpdateResponseKYBKYCPatchResponseVerificationApplicationStatus) IsKnown added in v0.68.0

type AccountHolderUpdateResponseKybkycPatchResponseBeneficialOwnerIndividual added in v0.68.0

type AccountHolderUpdateResponseKybkycPatchResponseBeneficialOwnerIndividual struct {
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address AccountHolderUpdateResponseKYBKYCPatchResponseBeneficialOwnerIndividualsAddress `json:"address"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob string `json:"dob"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email string `json:"email"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName string `json:"first_name"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName string `json:"last_name"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber string                                                                      `json:"phone_number"`
	JSON        accountHolderUpdateResponseKybkycPatchResponseBeneficialOwnerIndividualJSON `json:"-"`
}

func (*AccountHolderUpdateResponseKybkycPatchResponseBeneficialOwnerIndividual) UnmarshalJSON added in v0.68.0

type AccountHolderUpdateResponseKybkycPatchResponseStatusReason added in v0.68.0

type AccountHolderUpdateResponseKybkycPatchResponseStatusReason string

Status Reasons for KYC/KYB enrollment states

const (
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonAddressVerificationFailure                      AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "ADDRESS_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonAgeThresholdFailure                             AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "AGE_THRESHOLD_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonCompleteVerificationFailure                     AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "COMPLETE_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonDobVerificationFailure                          AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "DOB_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonIDVerificationFailure                           AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "ID_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonMaxDocumentAttempts                             AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "MAX_DOCUMENT_ATTEMPTS"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonMaxResubmissionAttempts                         AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "MAX_RESUBMISSION_ATTEMPTS"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonNameVerificationFailure                         AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "NAME_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonOtherVerificationFailure                        AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "OTHER_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonRiskThresholdFailure                            AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "RISK_THRESHOLD_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonWatchlistAlertFailure                           AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "WATCHLIST_ALERT_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonPrimaryBusinessEntityIDVerificationFailure      AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_ID_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonPrimaryBusinessEntityAddressVerificationFailure AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_ADDRESS_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonPrimaryBusinessEntityNameVerificationFailure    AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_NAME_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonPrimaryBusinessEntityBusinessOfficersNotMatched AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_BUSINESS_OFFICERS_NOT_MATCHED"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonPrimaryBusinessEntitySosFilingInactive          AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_SOS_FILING_INACTIVE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonPrimaryBusinessEntitySosNotMatched              AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_SOS_NOT_MATCHED"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonPrimaryBusinessEntityCmraFailure                AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_CMRA_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonPrimaryBusinessEntityWatchlistFailure           AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_WATCHLIST_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonPrimaryBusinessEntityRegisteredAgentFailure     AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "PRIMARY_BUSINESS_ENTITY_REGISTERED_AGENT_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonControlPersonBlocklistAlertFailure              AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "CONTROL_PERSON_BLOCKLIST_ALERT_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonControlPersonIDVerificationFailure              AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "CONTROL_PERSON_ID_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonControlPersonDobVerificationFailure             AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "CONTROL_PERSON_DOB_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseStatusReasonControlPersonNameVerificationFailure            AccountHolderUpdateResponseKybkycPatchResponseStatusReason = "CONTROL_PERSON_NAME_VERIFICATION_FAILURE"
)

func (AccountHolderUpdateResponseKybkycPatchResponseStatusReason) IsKnown added in v0.68.0

type AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason added in v0.68.0

type AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason string

Status Reasons for KYC/KYB enrollment states

const (
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonAddressVerificationFailure                      AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "ADDRESS_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonAgeThresholdFailure                             AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "AGE_THRESHOLD_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonCompleteVerificationFailure                     AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "COMPLETE_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonDobVerificationFailure                          AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "DOB_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonIDVerificationFailure                           AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "ID_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonMaxDocumentAttempts                             AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "MAX_DOCUMENT_ATTEMPTS"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonMaxResubmissionAttempts                         AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "MAX_RESUBMISSION_ATTEMPTS"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonNameVerificationFailure                         AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "NAME_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonOtherVerificationFailure                        AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "OTHER_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonRiskThresholdFailure                            AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "RISK_THRESHOLD_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonWatchlistAlertFailure                           AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "WATCHLIST_ALERT_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonPrimaryBusinessEntityIDVerificationFailure      AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_ID_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonPrimaryBusinessEntityAddressVerificationFailure AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_ADDRESS_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonPrimaryBusinessEntityNameVerificationFailure    AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_NAME_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonPrimaryBusinessEntityBusinessOfficersNotMatched AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_BUSINESS_OFFICERS_NOT_MATCHED"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonPrimaryBusinessEntitySosFilingInactive          AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_SOS_FILING_INACTIVE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonPrimaryBusinessEntitySosNotMatched              AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_SOS_NOT_MATCHED"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonPrimaryBusinessEntityCmraFailure                AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_CMRA_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonPrimaryBusinessEntityWatchlistFailure           AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_WATCHLIST_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonPrimaryBusinessEntityRegisteredAgentFailure     AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "PRIMARY_BUSINESS_ENTITY_REGISTERED_AGENT_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonControlPersonBlocklistAlertFailure              AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "CONTROL_PERSON_BLOCKLIST_ALERT_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonControlPersonIDVerificationFailure              AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "CONTROL_PERSON_ID_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonControlPersonDobVerificationFailure             AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "CONTROL_PERSON_DOB_VERIFICATION_FAILURE"
	AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReasonControlPersonNameVerificationFailure            AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason = "CONTROL_PERSON_NAME_VERIFICATION_FAILURE"
)

func (AccountHolderUpdateResponseKybkycPatchResponseVerificationApplicationStatusReason) IsKnown added in v0.68.0

type AccountHolderUpdateResponsePatchResponse added in v0.68.0

type AccountHolderUpdateResponsePatchResponse struct {
	// The token for the account holder that was updated
	Token string `json:"token"`
	// The address for the account holder
	Address AccountHolderUpdateResponsePatchResponseAddress `json:"address"`
	// The token for the business account that the account holder is associated with
	BusinessAccountToken string `json:"business_account_token,nullable"`
	// The email for the account holder
	Email string `json:"email"`
	// The first name for the account holder
	FirstName string `json:"first_name"`
	// The last name for the account holder
	LastName string `json:"last_name"`
	// The legal business name for the account holder
	LegalBusinessName string `json:"legal_business_name"`
	// The phone_number for the account holder
	PhoneNumber string                                       `json:"phone_number"`
	JSON        accountHolderUpdateResponsePatchResponseJSON `json:"-"`
}

func (*AccountHolderUpdateResponsePatchResponse) UnmarshalJSON added in v0.68.0

func (r *AccountHolderUpdateResponsePatchResponse) UnmarshalJSON(data []byte) (err error)

type AccountHolderUpdateResponsePatchResponseAddress added in v0.68.0

type AccountHolderUpdateResponsePatchResponseAddress struct {
	// Valid deliverable address (no PO boxes).
	Address1 string `json:"address1,required"`
	// Name of city.
	City string `json:"city,required"`
	// Valid country code. Only USA is currently supported, entered in uppercase ISO
	// 3166-1 alpha-3 three-character format.
	Country string `json:"country,required"`
	// Valid postal code. Only USA ZIP codes are currently supported, entered as a
	// five-digit ZIP or nine-digit ZIP+4.
	PostalCode string `json:"postal_code,required"`
	// Valid state code. Only USA state codes are currently supported, entered in
	// uppercase ISO 3166-2 two-character format.
	State string `json:"state,required"`
	// Unit or apartment number (if applicable).
	Address2 string                                              `json:"address2"`
	JSON     accountHolderUpdateResponsePatchResponseAddressJSON `json:"-"`
}

The address for the account holder

func (*AccountHolderUpdateResponsePatchResponseAddress) UnmarshalJSON added in v0.68.0

func (r *AccountHolderUpdateResponsePatchResponseAddress) UnmarshalJSON(data []byte) (err error)

type AccountHolderUpdateResponseStatus added in v0.68.0

type AccountHolderUpdateResponseStatus string

(Deprecated. Use verification_application.status instead) KYC and KYB evaluation states.

Note: `PENDING_RESUBMIT` and `PENDING_DOCUMENT` are only applicable for the `ADVANCED` workflow.

const (
	AccountHolderUpdateResponseStatusAccepted        AccountHolderUpdateResponseStatus = "ACCEPTED"
	AccountHolderUpdateResponseStatusPendingDocument AccountHolderUpdateResponseStatus = "PENDING_DOCUMENT"
	AccountHolderUpdateResponseStatusPendingResubmit AccountHolderUpdateResponseStatus = "PENDING_RESUBMIT"
	AccountHolderUpdateResponseStatusRejected        AccountHolderUpdateResponseStatus = "REJECTED"
)

func (AccountHolderUpdateResponseStatus) IsKnown added in v0.68.0

type AccountHolderUpdateResponseUnion added in v0.68.0

type AccountHolderUpdateResponseUnion interface {
	// contains filtered or unexported methods
}

Union satisfied by AccountHolderUpdateResponseKYBKYCPatchResponse or AccountHolderUpdateResponsePatchResponse.

type AccountHolderUpdateResponseUserType added in v0.68.0

type AccountHolderUpdateResponseUserType string

The type of Account Holder. If the type is "INDIVIDUAL", the "individual" attribute will be present.

If the type is "BUSINESS" then the "business_entity", "control_person", "beneficial_owner_individuals", "nature_of_business", and "website_url" attributes will be present.

const (
	AccountHolderUpdateResponseUserTypeBusiness   AccountHolderUpdateResponseUserType = "BUSINESS"
	AccountHolderUpdateResponseUserTypeIndividual AccountHolderUpdateResponseUserType = "INDIVIDUAL"
)

func (AccountHolderUpdateResponseUserType) IsKnown added in v0.68.0

type AccountHolderUpdatedWebhookEvent added in v0.98.0

type AccountHolderUpdatedWebhookEvent struct {
	// The token of the account_holder that was created.
	Token string `json:"token,required" format:"uuid"`
	// If applicable, represents the business account token associated with the
	// account_holder.
	BusinessAccountToken string `json:"business_account_token,nullable" format:"uuid"`
	// When the account_holder updated event was created
	Created time.Time `json:"created" format:"date-time"`
	// If updated, the newly updated email associated with the account_holder otherwise
	// the existing email is provided.
	Email string `json:"email"`
	// The type of event that occurred.
	EventType AccountHolderUpdatedWebhookEventEventType `json:"event_type"`
	// A user provided id that can be used to link an account holder with an external
	// system
	ExternalID string `json:"external_id,nullable"`
	// If applicable, represents the account_holder's first name.
	FirstName string `json:"first_name"`
	// If applicable, represents the account_holder's last name.
	LastName string `json:"last_name"`
	// If applicable, represents the account_holder's business name.
	LegalBusinessName string `json:"legal_business_name"`
	// Short description of the company's line of business (i.e., what does the company
	// do?).
	NatureOfBusiness string `json:"nature_of_business"`
	// If updated, the newly updated phone_number associated with the account_holder
	// otherwise the existing phone_number is provided.
	PhoneNumber string `json:"phone_number"`
	// This field can have the runtime type of
	// [AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequest],
	// [AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequest].
	UpdateRequest interface{} `json:"update_request"`
	// Company website URL.
	WebsiteURL string                               `json:"website_url"`
	JSON       accountHolderUpdatedWebhookEventJSON `json:"-"`
	// contains filtered or unexported fields
}

KYB payload for an updated account holder.

func (AccountHolderUpdatedWebhookEvent) AsUnion added in v0.98.0

AsUnion returns a AccountHolderUpdatedWebhookEventUnion interface which you can cast to the specific types for more type safety.

Possible runtime types of the union are AccountHolderUpdatedWebhookEventKYBPayload, AccountHolderUpdatedWebhookEventKYCPayload, AccountHolderUpdatedWebhookEventLegacyPayload.

func (*AccountHolderUpdatedWebhookEvent) UnmarshalJSON added in v0.98.0

func (r *AccountHolderUpdatedWebhookEvent) UnmarshalJSON(data []byte) (err error)

type AccountHolderUpdatedWebhookEventEventType added in v0.98.0

type AccountHolderUpdatedWebhookEventEventType string

The type of event that occurred.

const (
	AccountHolderUpdatedWebhookEventEventTypeAccountHolderUpdated AccountHolderUpdatedWebhookEventEventType = "account_holder.updated"
)

func (AccountHolderUpdatedWebhookEventEventType) IsKnown added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayload added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayload struct {
	// The token of the account_holder that was created.
	Token string `json:"token,required" format:"uuid"`
	// Original request to update the account holder.
	UpdateRequest AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequest `json:"update_request,required"`
	// The type of event that occurred.
	EventType AccountHolderUpdatedWebhookEventKYBPayloadEventType `json:"event_type"`
	// A user provided id that can be used to link an account holder with an external
	// system
	ExternalID string `json:"external_id"`
	// Short description of the company's line of business (i.e., what does the company
	// do?).
	NatureOfBusiness string `json:"nature_of_business"`
	// Company website URL.
	WebsiteURL string                                         `json:"website_url"`
	JSON       accountHolderUpdatedWebhookEventKYBPayloadJSON `json:"-"`
}

KYB payload for an updated account holder.

func (*AccountHolderUpdatedWebhookEventKYBPayload) UnmarshalJSON added in v0.98.0

func (r *AccountHolderUpdatedWebhookEventKYBPayload) UnmarshalJSON(data []byte) (err error)

type AccountHolderUpdatedWebhookEventKYBPayloadEventType added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayloadEventType string

The type of event that occurred.

const (
	AccountHolderUpdatedWebhookEventKYBPayloadEventTypeAccountHolderUpdated AccountHolderUpdatedWebhookEventKYBPayloadEventType = "account_holder.updated"
)

func (AccountHolderUpdatedWebhookEventKYBPayloadEventType) IsKnown added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequest added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequest struct {
	// Deprecated.
	//
	// Deprecated: deprecated
	BeneficialOwnerEntities []KYBBusinessEntity `json:"beneficial_owner_entities"`
	// You must submit a list of all direct and indirect individuals with 25% or more
	// ownership in the company. A maximum of 4 beneficial owners can be submitted. If
	// no individual owns 25% of the company you do not need to send beneficial owner
	// information. See
	// [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf)
	// (Section I) for more background on individuals that should be included.
	BeneficialOwnerIndividuals []AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestBeneficialOwnerIndividual `json:"beneficial_owner_individuals"`
	// Information for business for which the account is being opened and KYB is being
	// run.
	BusinessEntity KYBBusinessEntity `json:"business_entity"`
	// An individual with significant responsibility for managing the legal entity
	// (e.g., a Chief Executive Officer, Chief Financial Officer, Chief Operating
	// Officer, Managing Member, General Partner, President, Vice President, or
	// Treasurer). This can be an executive, or someone who will have program-wide
	// access to the cards that Lithic will provide. In some cases, this individual
	// could also be a beneficial owner listed above. See
	// [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf)
	// (Section II) for more background.
	ControlPerson AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestControlPerson `json:"control_person"`
	JSON          accountHolderUpdatedWebhookEventKYBPayloadUpdateRequestJSON          `json:"-"`
}

Original request to update the account holder.

func (*AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequest) UnmarshalJSON added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestBeneficialOwnerIndividual added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestBeneficialOwnerIndividual struct {
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestBeneficialOwnerIndividualsAddress `json:"address"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob string `json:"dob"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email string `json:"email"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName string `json:"first_name"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName string `json:"last_name"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber string                                                                               `json:"phone_number"`
	JSON        accountHolderUpdatedWebhookEventKYBPayloadUpdateRequestBeneficialOwnerIndividualJSON `json:"-"`
}

func (*AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestBeneficialOwnerIndividual) UnmarshalJSON added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestBeneficialOwnerIndividualsAddress added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestBeneficialOwnerIndividualsAddress struct {
	// Valid deliverable address (no PO boxes).
	Address1 string `json:"address1,required"`
	// Name of city.
	City string `json:"city,required"`
	// Valid country code. Only USA is currently supported, entered in uppercase ISO
	// 3166-1 alpha-3 three-character format.
	Country string `json:"country,required"`
	// Valid postal code. Only USA ZIP codes are currently supported, entered as a
	// five-digit ZIP or nine-digit ZIP+4.
	PostalCode string `json:"postal_code,required"`
	// Valid state code. Only USA state codes are currently supported, entered in
	// uppercase ISO 3166-2 two-character format.
	State string `json:"state,required"`
	// Unit or apartment number (if applicable).
	Address2 string                                                                                       `json:"address2"`
	JSON     accountHolderUpdatedWebhookEventKYBPayloadUpdateRequestBeneficialOwnerIndividualsAddressJSON `json:"-"`
}

Individual's current address - PO boxes, UPS drops, and FedEx drops are not acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.

func (*AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestBeneficialOwnerIndividualsAddress) UnmarshalJSON added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestControlPerson added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestControlPerson struct {
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestControlPersonAddress `json:"address"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob string `json:"dob"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email string `json:"email"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName string `json:"first_name"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName string `json:"last_name"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber string                                                                   `json:"phone_number"`
	JSON        accountHolderUpdatedWebhookEventKYBPayloadUpdateRequestControlPersonJSON `json:"-"`
}

An individual with significant responsibility for managing the legal entity (e.g., a Chief Executive Officer, Chief Financial Officer, Chief Operating Officer, Managing Member, General Partner, President, Vice President, or Treasurer). This can be an executive, or someone who will have program-wide access to the cards that Lithic will provide. In some cases, this individual could also be a beneficial owner listed above. See [FinCEN requirements](https://www.fincen.gov/sites/default/files/shared/CDD_Rev6.7_Sept_2017_Certificate.pdf) (Section II) for more background.

func (*AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestControlPerson) UnmarshalJSON added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestControlPersonAddress added in v0.98.0

type AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestControlPersonAddress struct {
	// Valid deliverable address (no PO boxes).
	Address1 string `json:"address1,required"`
	// Name of city.
	City string `json:"city,required"`
	// Valid country code. Only USA is currently supported, entered in uppercase ISO
	// 3166-1 alpha-3 three-character format.
	Country string `json:"country,required"`
	// Valid postal code. Only USA ZIP codes are currently supported, entered as a
	// five-digit ZIP or nine-digit ZIP+4.
	PostalCode string `json:"postal_code,required"`
	// Valid state code. Only USA state codes are currently supported, entered in
	// uppercase ISO 3166-2 two-character format.
	State string `json:"state,required"`
	// Unit or apartment number (if applicable).
	Address2 string                                                                          `json:"address2"`
	JSON     accountHolderUpdatedWebhookEventKYBPayloadUpdateRequestControlPersonAddressJSON `json:"-"`
}

Individual's current address - PO boxes, UPS drops, and FedEx drops are not acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.

func (*AccountHolderUpdatedWebhookEventKYBPayloadUpdateRequestControlPersonAddress) UnmarshalJSON added in v0.98.0

type AccountHolderUpdatedWebhookEventKYCPayload added in v0.98.0

type AccountHolderUpdatedWebhookEventKYCPayload struct {
	// The token of the account_holder that was created.
	Token string `json:"token,required" format:"uuid"`
	// Original request to update the account holder.
	UpdateRequest AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequest `json:"update_request,required"`
	// The type of event that occurred.
	EventType AccountHolderUpdatedWebhookEventKYCPayloadEventType `json:"event_type"`
	// A user provided id that can be used to link an account holder with an external
	// system
	ExternalID string                                         `json:"external_id"`
	JSON       accountHolderUpdatedWebhookEventKYCPayloadJSON `json:"-"`
}

KYC payload for an updated account holder.

func (*AccountHolderUpdatedWebhookEventKYCPayload) UnmarshalJSON added in v0.98.0

func (r *AccountHolderUpdatedWebhookEventKYCPayload) UnmarshalJSON(data []byte) (err error)

type AccountHolderUpdatedWebhookEventKYCPayloadEventType added in v0.98.0

type AccountHolderUpdatedWebhookEventKYCPayloadEventType string

The type of event that occurred.

const (
	AccountHolderUpdatedWebhookEventKYCPayloadEventTypeAccountHolderUpdated AccountHolderUpdatedWebhookEventKYCPayloadEventType = "account_holder.updated"
)

func (AccountHolderUpdatedWebhookEventKYCPayloadEventType) IsKnown added in v0.98.0

type AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequest added in v0.98.0

type AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequest struct {
	// Information on the individual for whom the account is being opened and KYC is
	// being run.
	Individual AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequestIndividual `json:"individual"`
	JSON       accountHolderUpdatedWebhookEventKYCPayloadUpdateRequestJSON       `json:"-"`
}

Original request to update the account holder.

func (*AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequest) UnmarshalJSON added in v0.98.0

type AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequestIndividual added in v0.98.0

type AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequestIndividual struct {
	// Individual's current address - PO boxes, UPS drops, and FedEx drops are not
	// acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.
	Address AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequestIndividualAddress `json:"address"`
	// Individual's date of birth, as an RFC 3339 date.
	Dob string `json:"dob"`
	// Individual's email address. If utilizing Lithic for chargeback processing, this
	// customer email address may be used to communicate dispute status and resolution.
	Email string `json:"email"`
	// Individual's first name, as it appears on government-issued identity documents.
	FirstName string `json:"first_name"`
	// Individual's last name, as it appears on government-issued identity documents.
	LastName string `json:"last_name"`
	// Individual's phone number, entered in E.164 format.
	PhoneNumber string                                                                `json:"phone_number"`
	JSON        accountHolderUpdatedWebhookEventKYCPayloadUpdateRequestIndividualJSON `json:"-"`
}

Information on the individual for whom the account is being opened and KYC is being run.

func (*AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequestIndividual) UnmarshalJSON added in v0.98.0

type AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequestIndividualAddress added in v0.98.0

type AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequestIndividualAddress struct {
	// Valid deliverable address (no PO boxes).
	Address1 string `json:"address1,required"`
	// Name of city.
	City string `json:"city,required"`
	// Valid country code. Only USA is currently supported, entered in uppercase ISO
	// 3166-1 alpha-3 three-character format.
	Country string `json:"country,required"`
	// Valid postal code. Only USA ZIP codes are currently supported, entered as a
	// five-digit ZIP or nine-digit ZIP+4.
	PostalCode string `json:"postal_code,required"`
	// Valid state code. Only USA state codes are currently supported, entered in
	// uppercase ISO 3166-2 two-character format.
	State string `json:"state,required"`
	// Unit or apartment number (if applicable).
	Address2 string                                                                       `json:"address2"`
	JSON     accountHolderUpdatedWebhookEventKYCPayloadUpdateRequestIndividualAddressJSON `json:"-"`
}

Individual's current address - PO boxes, UPS drops, and FedEx drops are not acceptable; APO/FPO are acceptable. Only USA addresses are currently supported.

func (*AccountHolderUpdatedWebhookEventKYCPayloadUpdateRequestIndividualAddress) UnmarshalJSON added in v0.98.0

type AccountHolderUpdatedWebhookEventLegacyPayload added in v0.98.0

type AccountHolderUpdatedWebhookEventLegacyPayload struct {
	// The token of the account_holder that was created.
	Token string `json:"token,required" format:"uuid"`
	// If applicable, represents the business account token associated with the
	// account_holder.
	BusinessAccountToken string `json:"business_account_token,nullable" format:"uuid"`
	// When the account_holder updated event was created
	Created time.Time `json:"created" format:"date-time"`
	// If updated, the newly updated email associated with the account_holder otherwise
	// the existing email is provided.
	Email string `json:"email"`
	// The type of event that occurred.
	EventType AccountHolderUpdatedWebhookEventLegacyPayloadEventType `json:"event_type"`
	// If applicable, represents the external_id associated with the account_holder.
	ExternalID string `json:"external_id,nullable"`
	// If applicable, represents the account_holder's first name.
	FirstName string `json:"first_name"`
	// If applicable, represents the account_holder's last name.
	LastName string `json:"last_name"`
	// If applicable, represents the account_holder's business name.
	LegalBusinessName string `json:"legal_business_name"`
	// If updated, the newly updated phone_number associated with the account_holder
	// otherwise the existing phone_number is provided.
	PhoneNumber string                                            `json:"phone_number"`
	JSON        accountHolderUpdatedWebhookEventLegacyPayloadJSON `json:"-"`
}

Legacy payload for an updated account holder.

func (*AccountHolderUpdatedWebhookEventLegacyPayload) UnmarshalJSON added in v0.98.0

func (r *AccountHolderUpdatedWebhookEventLegacyPayload) UnmarshalJSON(data []byte) (err error)

type AccountHolderUpdatedWebhookEventLegacyPayloadEventType added in v0.98.0

type AccountHolderUpdatedWebhookEventLegacyPayloadEventType string

The type of event that occurred.

const (
	AccountHolderUpdatedWebhookEventLegacyPayloadEventTypeAccountHolderUpdated AccountHolderUpdatedWebhookEventLegacyPayloadEventType = "account_holder.updated"
)

func (AccountHolderUpdatedWebhookEventLegacyPayloadEventType) IsKnown added in v0.98.0

type AccountHolderUpdatedWebhookEventUnion added in v0.98.0

type AccountHolderUpdatedWebhookEventUnion interface {
	// contains filtered or unexported methods
}

KYB payload for an updated account holder.

Union satisfied by AccountHolderUpdatedWebhookEventKYBPayload, AccountHolderUpdatedWebhookEventKYCPayload or AccountHolderUpdatedWebhookEventLegacyPayload.

type AccountHolderUploadDocumentParams

type AccountHolderUploadDocumentParams struct {
	// The type of document to upload
	DocumentType param.Field[AccountHolderUploadDocumentParamsDocumentType] `json:"document_type,required"`
	// Globally unique identifier for the entity.
	EntityToken param.Field[string] `json:"entity_token,required" format:"uuid"`
}

func (AccountHolderUploadDocumentParams) MarshalJSON

func (r AccountHolderUploadDocumentParams) MarshalJSON() (data []byte, err error)

type AccountHolderUploadDocumentParamsDocumentType

type AccountHolderUploadDocumentParamsDocumentType string

The type of document to upload

const (
	AccountHolderUploadDocumentParamsDocumentTypeEinLetter                 AccountHolderUploadDocumentParamsDocumentType = "EIN_LETTER"
	AccountHolderUploadDocumentParamsDocumentTypeTaxReturn                 AccountHolderUploadDocumentParamsDocumentType = "TAX_RETURN"
	AccountHolderUploadDocumentParamsDocumentTypeOperatingAgreement        AccountHolderUploadDocumentParamsDocumentType = "OPERATING_AGREEMENT"
	AccountHolderUploadDocumentParamsDocumentTypeCertificateOfFormation    AccountHolderUploadDocumentParamsDocumentType = "CERTIFICATE_OF_FORMATION"
	AccountHolderUploadDocumentParamsDocumentTypeDriversLicense            AccountHolderUploadDocumentParamsDocumentType = "DRIVERS_LICENSE"
	AccountHolderUploadDocumentParamsDocumentTypePassport                  AccountHolderUploadDocumentParamsDocumentType = "PASSPORT"
	AccountHolderUploadDocumentParamsDocumentTypePassportCard              AccountHolderUploadDocumentParamsDocumentType = "PASSPORT_CARD"
	AccountHolderUploadDocumentParamsDocumentTypeCertificateOfGoodStanding AccountHolderUploadDocumentParamsDocumentType = "CERTIFICATE_OF_GOOD_STANDING"
	AccountHolderUploadDocumentParamsDocumentTypeArticlesOfIncorporation   AccountHolderUploadDocumentParamsDocumentType = "ARTICLES_OF_INCORPORATION"
	AccountHolderUploadDocumentParamsDocumentTypeArticlesOfOrganization    AccountHolderUploadDocumentParamsDocumentType = "ARTICLES_OF_ORGANIZATION"
	AccountHolderUploadDocumentParamsDocumentTypeBylaws                    AccountHolderUploadDocumentParamsDocumentType = "BYLAWS"
	AccountHolderUploadDocumentParamsDocumentTypeGovernmentBusinessLicense AccountHolderUploadDocumentParamsDocumentType = "GOVERNMENT_BUSINESS_LICENSE"
	AccountHolderUploadDocumentParamsDocumentTypePartnershipAgreement      AccountHolderUploadDocumentParamsDocumentType = "PARTNERSHIP_AGREEMENT"
	AccountHolderUploadDocumentParamsDocumentTypeSs4Form                   AccountHolderUploadDocumentParamsDocumentType = "SS4_FORM"
	AccountHolderUploadDocumentParamsDocumentTypeBankStatement             AccountHolderUploadDocumentParamsDocumentType = "BANK_STATEMENT"
	AccountHolderUploadDocumentParamsDocumentTypeUtilityBillStatement      AccountHolderUploadDocumentParamsDocumentType = "UTILITY_BILL_STATEMENT"
	AccountHolderUploadDocumentParamsDocumentTypeSsnCard                   AccountHolderUploadDocumentParamsDocumentType = "SSN_CARD"
	AccountHolderUploadDocumentParamsDocumentTypeItinLetter                AccountHolderUploadDocumentParamsDocumentType = "ITIN_LETTER"
	AccountHolderUploadDocumentParamsDocumentTypeFincenBoiReport           AccountHolderUploadDocumentParamsDocumentType = "FINCEN_BOI_REPORT"
)

func (AccountHolderUploadDocumentParamsDocumentType) IsKnown added in v0.27.0

type AccountHolderUserType added in v0.8.0

type AccountHolderUserType string

The type of Account Holder. If the type is "INDIVIDUAL", the "individual" attribute will be present. If the type is "BUSINESS" then the "business_entity", "control_person", "beneficial_owner_individuals", "nature_of_business", and "website_url" attributes will be present.

const (
	AccountHolderUserTypeBusiness   AccountHolderUserType = "BUSINESS"
	AccountHolderUserTypeIndividual AccountHolderUserType = "INDIVIDUAL"
)

func (AccountHolderUserType) IsKnown added in v0.27.0

func (r AccountHolderUserType) IsKnown() bool

type AccountHolderVerificationApplication added in v0.8.0

type AccountHolderVerificationApplication struct {
	// Timestamp of when the application was created.
	Created time.Time `json:"created" format:"date-time"`
	// KYC and KYB evaluation states.
	//
	// Note:
	//
	// - `PENDING_REVIEW` is only applicable for the `KYB_BASIC` workflow.
	Status AccountHolderVerificationApplicationStatus `json:"status"`
	// Reason for the evaluation status.
	StatusReasons []AccountHolderVerificationApplicationStatusReason `json:"status_reasons"`
	// Timestamp of when the application was last updated.
	Updated time.Time                                `json:"updated" format:"date-time"`
	JSON    accountHolderVerificationApplicationJSON `json:"-"`
}

Information about the most recent identity verification attempt

func (*AccountHolderVerificationApplication) UnmarshalJSON added in v0.8.0

func (r *AccountHolderVerificationApplication) UnmarshalJSON(data []byte) (err error)

type AccountHolderVerificationApplicationStatus added in v0.8.0

type AccountHolderVerificationApplicationStatus string

KYC and KYB evaluation states.

Note:

- `PENDING_REVIEW` is only applicable for the `KYB_BASIC` workflow.

const (
	AccountHolderVerificationApplicationStatusAccepted        AccountHolderVerificationApplicationStatus = "ACCEPTED"
	AccountHolderVerificationApplicationStatusPendingReview   AccountHolderVerificationApplicationStatus = "PENDING_REVIEW"
	AccountHolderVerificationApplicationStatusPendingDocument AccountHolderVerificationApplicationStatus = "PENDING_DOCUMENT"
	AccountHolderVerificationApplicationStatusPendingResubmit AccountHolderVerificationApplicationStatus = "PENDING_RESUBMIT"
	AccountHolderVerificationApplicationStatusRejected        AccountHolderVerificationApplicationStatus = "REJECTED"
)

func (AccountHolderVerificationApplicationStatus) IsKnown added in v0.27.0

type AccountHolderVerificationApplicationStatusReason added in v0.8.0

type AccountHolderVerificationApplicationStatusReason string
const (
	AccountHolderVerificationApplicationStatusReasonAddressVerificationFailure  AccountHolderVerificationApplicationStatusReason = "ADDRESS_VERIFICATION_FAILURE"
	AccountHolderVerificationApplicationStatusReasonAgeThresholdFailure         AccountHolderVerificationApplicationStatusReason = "AGE_THRESHOLD_FAILURE"
	AccountHolderVerificationApplicationStatusReasonCompleteVerificationFailure AccountHolderVerificationApplicationStatusReason = "COMPLETE_VERIFICATION_FAILURE"
	AccountHolderVerificationApplicationStatusReasonDobVerificationFailure      AccountHolderVerificationApplicationStatusReason = "DOB_VERIFICATION_FAILURE"
	AccountHolderVerificationApplicationStatusReasonIDVerificationFailure       AccountHolderVerificationApplicationStatusReason = "ID_VERIFICATION_FAILURE"
	AccountHolderVerificationApplicationStatusReasonMaxDocumentAttempts         AccountHolderVerificationApplicationStatusReason = "MAX_DOCUMENT_ATTEMPTS"
	AccountHolderVerificationApplicationStatusReasonMaxResubmissionAttempts     AccountHolderVerificationApplicationStatusReason = "MAX_RESUBMISSION_ATTEMPTS"
	AccountHolderVerificationApplicationStatusReasonNameVerificationFailure     AccountHolderVerificationApplicationStatusReason = "NAME_VERIFICATION_FAILURE"
	AccountHolderVerificationApplicationStatusReasonOtherVerificationFailure    AccountHolderVerificationApplicationStatusReason = "OTHER_VERIFICATION_FAILURE"
	AccountHolderVerificationApplicationStatusReasonRiskThresholdFailure        AccountHolderVerificationApplicationStatusReason = "RISK_THRESHOLD_FAILURE"
	AccountHolderVerificationApplicationStatusReasonWatchlistAlertFailure       AccountHolderVerificationApplicationStatusReason = "WATCHLIST_ALERT_FAILURE"
)

func (AccountHolderVerificationApplicationStatusReason) IsKnown added in v0.27.0

type AccountHolderVerificationWebhookEvent added in v0.98.0

type AccountHolderVerificationWebhookEvent struct {
	// The type of event that occurred.
	EventType AccountHolderVerificationWebhookEventEventType `json:"event_type,required"`
	// The token of the account_holder being verified.
	Token string `json:"token" format:"uuid"`
	// The token of the account being verified.
	AccountToken string `json:"account_token" format:"uuid"`
	// When the account_holder verification status was updated
	Created time.Time `json:"created" format:"date-time"`
	// The status of the account_holder that was created
	Status        AccountHolderVerificationWebhookEventStatus `json:"status"`
	StatusReasons []string                                    `json:"status_reasons"`
	JSON          accountHolderVerificationWebhookEventJSON   `json:"-"`
}

func (*AccountHolderVerificationWebhookEvent) UnmarshalJSON added in v0.98.0

func (r *AccountHolderVerificationWebhookEvent) UnmarshalJSON(data []byte) (err error)

type AccountHolderVerificationWebhookEventEventType added in v0.98.0

type AccountHolderVerificationWebhookEventEventType string

The type of event that occurred.

const (
	AccountHolderVerificationWebhookEventEventTypeAccountHolderVerification AccountHolderVerificationWebhookEventEventType = "account_holder.verification"
)

func (AccountHolderVerificationWebhookEventEventType) IsKnown added in v0.98.0

type AccountHolderVerificationWebhookEventStatus added in v0.98.0

type AccountHolderVerificationWebhookEventStatus string

The status of the account_holder that was created

const (
	AccountHolderVerificationWebhookEventStatusAccepted      AccountHolderVerificationWebhookEventStatus = "ACCEPTED"
	AccountHolderVerificationWebhookEventStatusPendingReview AccountHolderVerificationWebhookEventStatus = "PENDING_REVIEW"
	AccountHolderVerificationWebhookEventStatusRejected      AccountHolderVerificationWebhookEventStatus = "REJECTED"
)

func (AccountHolderVerificationWebhookEventStatus) IsKnown added in v0.98.0

type AccountListParams

type AccountListParams struct {
	// Date string in RFC 3339 format. Only entries created after the specified time
	// will be included. UTC time zone.
	Begin param.Field[time.Time] `query:"begin" format:"date-time"`
	// Date string in RFC 3339 format. Only entries created before the specified time
	// will be included. UTC time zone.
	End param.Field[time.Time] `query:"end" format:"date-time"`
	// A cursor representing an item's token before which a page of results should end.
	// Used to retrieve the previous page of results before this item.
	EndingBefore param.Field[string] `query:"ending_before"`
	// Page size (for pagination).
	PageSize param.Field[int64] `query:"page_size"`
	// A cursor representing an item's token after which a page of results should
	// begin. Used to retrieve the next page of results after this item.
	StartingAfter param.Field[string] `query:"starting_after"`
}

func (AccountListParams) URLQuery

func (r AccountListParams) URLQuery() (v url.Values)

URLQuery serializes AccountListParams's query parameters as `url.Values`.

type AccountService

type AccountService struct {
	Options []option.RequestOption
}

AccountService contains methods and other services that help with interacting with the lithic API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAccountService method instead.

func NewAccountService

func NewAccountService(opts ...option.RequestOption) (r *AccountService)

NewAccountService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*AccountService) Get

func (r *AccountService) Get(ctx context.Context, accountToken string, opts ...option.RequestOption) (res *Account, err error)

Get account configuration such as spend limits.

func (*AccountService) GetSpendLimits added in v0.15.0

func (r *AccountService) GetSpendLimits(ctx context.Context, accountToken string, opts ...option.RequestOption) (res *AccountSpendLimits, err error)

Get an Account's available spend limits, which is based on the spend limit configured on the Account and the amount already spent over the spend limit's duration. For example, if the Account has a daily spend limit of $1000 configured, and has spent $600 in the last 24 hours, the available spend limit returned would be $400.

func (*AccountService) List

List account configurations.

func (*AccountService) ListAutoPaging

List account configurations.

func (*AccountService) Update

func (r *AccountService) Update(ctx context.Context, accountToken string, body AccountUpdateParams, opts ...option.RequestOption) (res *Account, err error)

Update account configuration such as state or spend limits. Can only be run on accounts that are part of the program managed by this API key. Accounts that are in the `PAUSED` state will not be able to transact or create new cards.

type AccountSpendLimit

type AccountSpendLimit struct {
	// Daily spend limit (in cents).
	Daily int64 `json:"daily,required"`
	// Total spend limit over account lifetime (in cents).
	Lifetime int64 `json:"lifetime,required"`
	// Monthly spend limit (in cents).
	Monthly int64                 `json:"monthly,required"`
	JSON    accountSpendLimitJSON `json:"-"`
}

Spend limit information for the user containing the daily, monthly, and lifetime spend limit of the account. Any charges to a card owned by this account will be declined once their transaction volume has surpassed the value in the applicable time limit (rolling). A lifetime limit of 0 indicates that the lifetime limit feature is disabled.

func (*AccountSpendLimit) UnmarshalJSON

func (r *AccountSpendLimit) UnmarshalJSON(data []byte) (err error)

type AccountSpendLimits added in v0.15.0

type AccountSpendLimits struct {
	AvailableSpendLimit AccountSpendLimitsAvailableSpendLimit `json:"available_spend_limit,required"`
	SpendLimit          AccountSpendLimitsSpendLimit          `json:"spend_limit"`
	SpendVelocity       AccountSpendLimitsSpendVelocity       `json:"spend_velocity"`
	JSON                accountSpendLimitsJSON                `json:"-"`
}

func (*AccountSpendLimits) UnmarshalJSON added in v0.15.0

func (r *AccountSpendLimits) UnmarshalJSON(data []byte) (err error)

type AccountSpendLimitsAvailableSpendLimit added in v0.15.0

type AccountSpendLimitsAvailableSpendLimit struct {
	// The available spend limit (in cents) relative to the daily limit configured on
	// the Account (e.g. 100000 would be a $1,000 limit).
	Daily int64 `json:"daily"`
	// The available spend limit (in cents) relative to the lifetime limit configured
	// on the Account.
	Lifetime int64 `json:"lifetime"`
	// The available spend limit (in cents) relative to the monthly limit configured on
	// the Account.
	Monthly int64                                     `json:"monthly"`
	JSON    accountSpendLimitsAvailableSpendLimitJSON `json:"-"`
}

func (*AccountSpendLimitsAvailableSpendLimit) UnmarshalJSON added in v0.15.0

func (r *AccountSpendLimitsAvailableSpendLimit) UnmarshalJSON(data []byte) (err error)

type AccountSpendLimitsSpendLimit added in v0.28.0

type AccountSpendLimitsSpendLimit struct {
	// The configured daily spend limit (in cents) on the Account.
	Daily int64 `json:"daily"`
	// The configured lifetime spend limit (in cents) on the Account.
	Lifetime int64 `json:"lifetime"`
	// The configured monthly spend limit (in cents) on the Account.
	Monthly int64                            `json:"monthly"`
	JSON    accountSpendLimitsSpendLimitJSON `json:"-"`
}

func (*AccountSpendLimitsSpendLimit) UnmarshalJSON added in v0.28.0

func (r *AccountSpendLimitsSpendLimit) UnmarshalJSON(data []byte) (err error)

type AccountSpendLimitsSpendVelocity added in v0.28.0

type AccountSpendLimitsSpendVelocity struct {
	// Current daily spend velocity (in cents) on the Account. Present if daily spend
	// limit is set.
	Daily int64 `json:"daily"`
	// Current lifetime spend velocity (in cents) on the Account. Present if lifetime
	// spend limit is set.
	Lifetime int64 `json:"lifetime"`
	// Current monthly spend velocity (in cents) on the Account. Present if monthly
	// spend limit is set.
	Monthly int64                               `json:"monthly"`
	JSON    accountSpendLimitsSpendVelocityJSON `json:"-"`
}

func (*AccountSpendLimitsSpendVelocity) UnmarshalJSON added in v0.28.0

func (r *AccountSpendLimitsSpendVelocity) UnmarshalJSON(data []byte) (err error)

type AccountState

type AccountState string

Account state:

  • `ACTIVE` - Account is able to transact and create new cards.
  • `PAUSED` - Account will not be able to transact or create new cards. It can be set back to `ACTIVE`.
  • `CLOSED` - Account will not be able to transact or create new cards. `CLOSED` accounts are unable to be transitioned to `ACTIVE` or `PAUSED` states. Accounts can be manually set to `CLOSED`, or this can be done by Lithic due to failure to pass KYB/KYC or for risk/compliance reasons. Please contact [[email protected]](mailto:[email protected]) if you believe this was done by mistake.
const (
	AccountStateActive AccountState = "ACTIVE"
	AccountStatePaused AccountState = "PAUSED"
	AccountStateClosed AccountState = "CLOSED"
)

func (AccountState) IsKnown added in v0.27.0

func (r AccountState) IsKnown() bool

type AccountSubstatus added in v0.84.0

type AccountSubstatus string

Account state substatus values:

  • `FRAUD_IDENTIFIED` - The account has been recognized as being created or used with stolen or fabricated identity information, encompassing both true identity theft and synthetic identities.
  • `SUSPICIOUS_ACTIVITY` - The account has exhibited suspicious behavior, such as unauthorized access or fraudulent transactions, necessitating further investigation.
  • `RISK_VIOLATION` - The account has been involved in deliberate misuse by the legitimate account holder. Examples include disputing valid transactions without cause, falsely claiming non-receipt of goods, or engaging in intentional bust-out schemes to exploit account services.
  • `END_USER_REQUEST` - The account holder has voluntarily requested the closure of the account for personal reasons. This encompasses situations such as bankruptcy, other financial considerations, or the account holder's death.
  • `ISSUER_REQUEST` - The issuer has initiated the closure of the account due to business strategy, risk management, inactivity, product changes, regulatory concerns, or violations of terms and conditions.
  • `NOT_ACTIVE` - The account has not had any transactions or payment activity within a specified period. This status applies to accounts that are paused or closed due to inactivity.
  • `INTERNAL_REVIEW` - The account is temporarily paused pending further internal review. In future implementations, this status may prevent clients from activating the account via APIs until the review is completed.
  • `OTHER` - The reason for the account's current status does not fall into any of the above categories. A comment should be provided to specify the particular reason.
const (
	AccountSubstatusFraudIdentified    AccountSubstatus = "FRAUD_IDENTIFIED"
	AccountSubstatusSuspiciousActivity AccountSubstatus = "SUSPICIOUS_ACTIVITY"
	AccountSubstatusRiskViolation      AccountSubstatus = "RISK_VIOLATION"
	AccountSubstatusEndUserRequest     AccountSubstatus = "END_USER_REQUEST"
	AccountSubstatusIssuerRequest      AccountSubstatus = "ISSUER_REQUEST"
	AccountSubstatusNotActive          AccountSubstatus = "NOT_ACTIVE"
	AccountSubstatusInternalReview     AccountSubstatus = "INTERNAL_REVIEW"
	AccountSubstatusOther              AccountSubstatus = "OTHER"
)

func (AccountSubstatus) IsKnown added in v0.84.0

func (r AccountSubstatus) IsKnown() bool

type AccountUpdateParams

type AccountUpdateParams struct {
	// Additional context or information related to the account.
	Comment param.Field[string] `json:"comment"`
	// Amount (in cents) for the account's daily spend limit (e.g. 100000 would be a
	// $1,000 limit). By default the daily spend limit is set to $1,250.
	DailySpendLimit param.Field[int64] `json:"daily_spend_limit"`
	// Amount (in cents) for the account's lifetime spend limit (e.g. 100000 would be a
	// $1,000 limit). Once this limit is reached, no transactions will be accepted on
	// any card created for this account until the limit is updated. Note that a spend
	// limit of 0 is effectively no limit, and should only be used to reset or remove a
	// prior limit. Only a limit of 1 or above will result in declined transactions due
	// to checks against the account limit. This behavior differs from the daily spend
	// limit and the monthly spend limit.
	LifetimeSpendLimit param.Field[int64] `json:"lifetime_spend_limit"`
	// Amount (in cents) for the account's monthly spend limit (e.g. 100000 would be a
	// $1,000 limit). By default the monthly spend limit is set to $5,000.
	MonthlySpendLimit param.Field[int64] `json:"monthly_spend_limit"`
	// Account states.
	State param.Field[AccountUpdateParamsState] `json:"state"`
	// Account state substatus values:
	//
	//   - `FRAUD_IDENTIFIED` - The account has been recognized as being created or used
	//     with stolen or fabricated identity information, encompassing both true
	//     identity theft and synthetic identities.
	//   - `SUSPICIOUS_ACTIVITY` - The account has exhibited suspicious behavior, such as
	//     unauthorized access or fraudulent transactions, necessitating further
	//     investigation.
	//   - `RISK_VIOLATION` - The account has been involved in deliberate misuse by the
	//     legitimate account holder. Examples include disputing valid transactions
	//     without cause, falsely claiming non-receipt of goods, or engaging in
	//     intentional bust-out schemes to exploit account services.
	//   - `END_USER_REQUEST` - The account holder has voluntarily requested the closure
	//     of the account for personal reasons. This encompasses situations such as
	//     bankruptcy, other financial considerations, or the account holder's death.
	//   - `ISSUER_REQUEST` - The issuer has initiated the closure of the account due to
	//     business strategy, risk management, inactivity, product changes, regulatory
	//     concerns, or violations of terms and conditions.
	//   - `NOT_ACTIVE` - The account has not had any transactions or payment activity
	//     within a specified period. This status applies to accounts that are paused or
	//     closed due to inactivity.
	//   - `INTERNAL_REVIEW` - The account is temporarily paused pending further internal
	//     review. In future implementations, this status may prevent clients from
	//     activating the account via APIs until the review is completed.
	//   - `OTHER` - The reason for the account's current status does not fall into any
	//     of the above categories. A comment should be provided to specify the
	//     particular reason.
	Substatus param.Field[AccountUpdateParamsSubstatus] `json:"substatus"`
	// Address used during Address Verification Service (AVS) checks during
	// transactions if enabled via Auth Rules. This field is deprecated as AVS checks
	// are no longer supported by Auth Rules. The field will be removed from the schema
	// in a future release.
	VerificationAddress param.Field[AccountUpdateParamsVerificationAddress] `json:"verification_address"`
}

func (AccountUpdateParams) MarshalJSON

func (r AccountUpdateParams) MarshalJSON() (data []byte, err error)

type AccountUpdateParamsState

type AccountUpdateParamsState string

Account states.

const (
	AccountUpdateParamsStateActive AccountUpdateParamsState = "ACTIVE"
	AccountUpdateParamsStatePaused AccountUpdateParamsState = "PAUSED"
	AccountUpdateParamsStateClosed AccountUpdateParamsState = "CLOSED"
)

func (AccountUpdateParamsState) IsKnown added in v0.27.0

func (r AccountUpdateParamsState) IsKnown() bool

type AccountUpdateParamsSubstatus added in v0.84.0

type AccountUpdateParamsSubstatus string

Account state substatus values:

  • `FRAUD_IDENTIFIED` - The account has been recognized as being created or used with stolen or fabricated identity information, encompassing both true identity theft and synthetic identities.
  • `SUSPICIOUS_ACTIVITY` - The account has exhibited suspicious behavior, such as unauthorized access or fraudulent transactions, necessitating further investigation.
  • `RISK_VIOLATION` - The account has been involved in deliberate misuse by the legitimate account holder. Examples include disputing valid transactions without cause, falsely claiming non-receipt of goods, or engaging in intentional bust-out schemes to exploit account services.
  • `END_USER_REQUEST` - The account holder has voluntarily requested the closure of the account for personal reasons. This encompasses situations such as bankruptcy, other financial considerations, or the account holder's death.
  • `ISSUER_REQUEST` - The issuer has initiated the closure of the account due to business strategy, risk management, inactivity, product changes, regulatory concerns, or violations of terms and conditions.
  • `NOT_ACTIVE` - The account has not had any transactions or payment activity within a specified period. This status applies to accounts that are paused or closed due to inactivity.
  • `INTERNAL_REVIEW` - The account is temporarily paused pending further internal review. In future implementations, this status may prevent clients from activating the account via APIs until the review is completed.
  • `OTHER` - The reason for the account's current status does not fall into any of the above categories. A comment should be provided to specify the particular reason.
const (
	AccountUpdateParamsSubstatusFraudIdentified    AccountUpdateParamsSubstatus = "FRAUD_IDENTIFIED"
	AccountUpdateParamsSubstatusSuspiciousActivity AccountUpdateParamsSubstatus = "SUSPICIOUS_ACTIVITY"
	AccountUpdateParamsSubstatusRiskViolation      AccountUpdateParamsSubstatus = "RISK_VIOLATION"
	AccountUpdateParamsSubstatusEndUserRequest     AccountUpdateParamsSubstatus = "END_USER_REQUEST"
	AccountUpdateParamsSubstatusIssuerRequest      AccountUpdateParamsSubstatus = "ISSUER_REQUEST"
	AccountUpdateParamsSubstatusNotActive          AccountUpdateParamsSubstatus = "NOT_ACTIVE"
	AccountUpdateParamsSubstatusInternalReview     AccountUpdateParamsSubstatus = "INTERNAL_REVIEW"
	AccountUpdateParamsSubstatusOther              AccountUpdateParamsSubstatus = "OTHER"
)

func (AccountUpdateParamsSubstatus) IsKnown added in v0.84.0

func (r AccountUpdateParamsSubstatus) IsKnown() bool

type AccountUpdateParamsVerificationAddress deprecated

type AccountUpdateParamsVerificationAddress struct {
	Address1   param.Field[string] `json:"address1"`
	Address2   param.Field[string] `json:"address2"`
	City       param.Field[string] `json:"city"`
	Country    param.Field[string] `json:"country"`
	PostalCode param.Field[string] `json:"postal_code"`
	State      param.Field[string] `json:"state"`
}

Address used during Address Verification Service (AVS) checks during transactions if enabled via Auth Rules. This field is deprecated as AVS checks are no longer supported by Auth Rules. The field will be removed from the schema in a future release.

Deprecated: deprecated

func (AccountUpdateParamsVerificationAddress) MarshalJSON added in v0.3.1

func (r AccountUpdateParamsVerificationAddress) MarshalJSON() (data []byte, err error)

type AccountVerificationAddress deprecated

type AccountVerificationAddress struct {
	// Valid deliverable address (no PO boxes).
	Address1 string `json:"address1,required"`
	// City name.
	City string `json:"city,required"`
	// Country name. Only USA is currently supported.
	Country string `json:"country,required"`
	// Valid postal code. Only USA postal codes (ZIP codes) are currently supported,
	// entered as a five-digit postal code or nine-digit postal code (ZIP+4) using the
	// format 12345-1234.
	PostalCode string `json:"postal_code,required"`
	// Valid state code. Only USA state codes are currently supported, entered in
	// uppercase ISO 3166-2 two-character format.
	State string `json:"state,required"`
	// Unit or apartment number (if applicable).
	Address2 string                         `json:"address2"`
	JSON     accountVerificationAddressJSON `json:"-"`
}

Deprecated: deprecated

func (*AccountVerificationAddress) UnmarshalJSON

func (r *AccountVerificationAddress) UnmarshalJSON(data []byte) (err error)