## List all documents `client.Documents.List(ctx, query) (*CursorPagination[Document], error)` **get** `/documents` Retrieve a paginated list of documents using cursor-based pagination ### Parameters - `query DocumentListParams` - `After param.Field[string]` Cursor for forward pagination. Returns items after this cursor. - `Before param.Field[string]` Cursor for backward pagination. Returns items before this cursor. - `HouseholdID param.Field[string]` Filter documents by household ID - `Limit param.Field[int64]` Maximum number of items to return - `Type param.Field[DocumentType]` Filter by document type ### Returns - `type Document struct{…}` - `ID string` Unique identifier with document_ prefix - `CreatedAt Time` Timestamp when the document was created - `HouseholdID string` Household ID this document belongs to - `Name string` Display name of the document - `Type DocumentType` Type of document - `const DocumentTypeGratDesignSummary DocumentType = "GRAT_DESIGN_SUMMARY"` - `const DocumentTypeGeneratedPresentation DocumentType = "GENERATED_PRESENTATION"` - `const DocumentTypeAssetValuation DocumentType = "ASSET_VALUATION"` - `const DocumentTypeSignedTrustDocument DocumentType = "SIGNED_TRUST_DOCUMENT"` - `const DocumentTypeTrustAmendment DocumentType = "TRUST_AMENDMENT"` - `const DocumentTypeTransferConfirmation DocumentType = "TRANSFER_CONFIRMATION"` - `const DocumentTypeExistingRemainderTrustDocument DocumentType = "EXISTING_REMAINDER_TRUST_DOCUMENT"` - `const DocumentTypeBalanceSheet DocumentType = "BALANCE_SHEET"` - `const DocumentTypeWill DocumentType = "WILL"` - `const DocumentTypeWillCodicil DocumentType = "WILL_CODICIL"` - `const DocumentTypePowerOfAttorney DocumentType = "POWER_OF_ATTORNEY"` - `const DocumentTypeAssignmentOfInterest DocumentType = "ASSIGNMENT_OF_INTEREST"` - `const DocumentTypeAssignmentOfTangibleProperty DocumentType = "ASSIGNMENT_OF_TANGIBLE_PROPERTY"` - `const DocumentTypeLoanNoteAgreement DocumentType = "LOAN_NOTE_AGREEMENT"` - `const DocumentTypeArticlesOfIncorporation DocumentType = "ARTICLES_OF_INCORPORATION"` - `const DocumentTypeOperatingAgreement DocumentType = "OPERATING_AGREEMENT"` - `const DocumentTypePartnershipAgreement DocumentType = "PARTNERSHIP_AGREEMENT"` - `const DocumentTypeAccountDocumentationStatement DocumentType = "ACCOUNT_DOCUMENTATION_STATEMENT"` - `const DocumentTypeTaxIDConfirmation DocumentType = "TAX_ID_CONFIRMATION"` - `const DocumentTypeGiftTaxReturn DocumentType = "GIFT_TAX_RETURN"` - `const DocumentTypeIncomeTaxReturn DocumentType = "INCOME_TAX_RETURN"` - `const DocumentTypeTaxReceipt DocumentType = "TAX_RECEIPT"` - `const DocumentTypeTaxFiling DocumentType = "TAX_FILING"` - `const DocumentTypeCorporateBylaws DocumentType = "CORPORATE_BYLAWS"` - `const DocumentTypeLlcAgreement DocumentType = "LLC_AGREEMENT"` - `const DocumentTypeLlcAgreementAmendment DocumentType = "LLC_AGREEMENT_AMENDMENT"` - `const DocumentTypeOperatingAgreementAmendment DocumentType = "OPERATING_AGREEMENT_AMENDMENT"` - `const DocumentTypePartnershipAgreementAmendment DocumentType = "PARTNERSHIP_AGREEMENT_AMENDMENT"` - `const DocumentTypeShareholdersAgreement DocumentType = "SHAREHOLDERS_AGREEMENT"` - `const DocumentTypeStateBusinessFiling DocumentType = "STATE_BUSINESS_FILING"` - `const DocumentTypeLoggedContribution DocumentType = "LOGGED_CONTRIBUTION"` - `const DocumentTypeLoggedDistribution DocumentType = "LOGGED_DISTRIBUTION"` - `const DocumentTypeInsurancePolicy DocumentType = "INSURANCE_POLICY"` - `const DocumentTypeCrummeyLetter DocumentType = "CRUMMEY_LETTER"` - `const DocumentTypeInsurancePremiumPayment DocumentType = "INSURANCE_PREMIUM_PAYMENT"` - `const DocumentTypeBeneficialOwnershipInformationReport DocumentType = "BENEFICIAL_OWNERSHIP_INFORMATION_REPORT"` - `const DocumentTypeFincenFiling DocumentType = "FINCEN_FILING"` - `const DocumentTypeHealthcareProxy DocumentType = "HEALTHCARE_PROXY"` - `const DocumentTypeLivingWill DocumentType = "LIVING_WILL"` - `const DocumentTypeDriversLicense DocumentType = "DRIVERS_LICENSE"` - `const DocumentTypePassport DocumentType = "PASSPORT"` - `const DocumentTypeDeed DocumentType = "DEED"` - `const DocumentTypeOther DocumentType = "OTHER"` - `UpdatedAt Time` Timestamp when the document was last updated - `EnableAISuggestions bool` Whether this document should be used for AI suggestions - `EntityID string` Entity ID if this document is owned by an entity - `IndividualID string` Individual ID if this document is associated with an individual ### Example ```go package main import ( "context" "fmt" "github.com/withluminary/go-sdk" "github.com/withluminary/go-sdk/option" ) func main() { client := withluminary.NewClient( option.WithClientID("My Client ID"), option.WithClientSecret("My Client Secret"), ) page, err := client.Documents.List(context.TODO(), withluminary.DocumentListParams{ }) if err != nil { panic(err.Error()) } fmt.Printf("%+v\n", page) } ``` #### Response ```json { "data": [ { "id": "document_01ARZ3NDEKTSV4RRFFQ69G5FAV", "created_at": "2024-01-15T09:30:00Z", "household_id": "household_01ARZ3NDEKTSV4RRFFQ69G5FAV", "name": "Trust Agreement.pdf", "type": "GRAT_DESIGN_SUMMARY", "updated_at": "2024-01-20T14:45:00Z", "enable_ai_suggestions": true, "entity_id": "entity_01ARZ3NDEKTSV4RRFFQ69G5FAV", "individual_id": "client_profile_01ARZ3NDEKTSV4RRFFQ69G5FAV" } ], "page_info": { "has_next_page": true, "has_previous_page": false, "end_cursor": "eyJpZCI6ImhvdXNlaG9sZF8wMUFSWjNOREVLVFNWNFJSRkZRNjlHNUZBViJ9", "start_cursor": "eyJpZCI6ImhvdXNlaG9sZF8wMUFSWjNOREVLVFNWNFJSRkZRNjlHNUZBViJ9" }, "total_count": 100 } ```