Versions in this module Expand all Collapse all v0 v0.1.0 Jul 15, 2026 Changes in this version + const DefaultBaseURL + const DefaultTimeout + func AuthorizationHeader(keyID, signature string) string + func VerifyWebhookSignature(rawBody []byte, signatureHeader string, secret string, ...) bool + type APIEnvelope struct + Data json.RawMessage + Error *APIError + Meta *EnvelopeMeta + type APIError struct + Code string + DocURL string + Message string + type AccountEmailChangeInput struct + NewEmail string + Password string + type AccountEmailChangeResult struct + PendingVerification bool + type AccountPasswordChangeInput struct + CurrentPassword string + NewPassword string + type AccountProfile struct + CreatedAt string + Email string + EmailVerified bool + ID string + MfaEnrolled bool + Name *string + type AccountResource struct + func (r *AccountResource) ChangeEmail(ctx context.Context, in AccountEmailChangeInput) (*AccountEmailChangeResult, error) + func (r *AccountResource) ChangePassword(ctx context.Context, in AccountPasswordChangeInput) error + func (r *AccountResource) Get(ctx context.Context) (*AccountProfile, error) + func (r *AccountResource) ListLinked(ctx context.Context) ([]LinkedAccount, error) + func (r *AccountResource) ListMembers(ctx context.Context) ([]WorkspaceMember, error) + func (r *AccountResource) ListSessions(ctx context.Context) ([]BrowserSession, error) + func (r *AccountResource) RevokeAllSessions(ctx context.Context) (*AccountRevokeAllResult, error) + func (r *AccountResource) RevokeSession(ctx context.Context, id string) error + func (r *AccountResource) Unlink(ctx context.Context, provider string) error + func (r *AccountResource) Update(ctx context.Context, patch AccountUpdateInput) (*AccountProfile, error) + type AccountRevokeAllResult struct + Revoked int64 + type AccountUpdateInput struct + Name *string + type AdapterConfig struct + Configured bool + Kind AdapterKind + PublicConfig map[string]any + UpdatedAt string + type AdapterKind string + const AdapterKindManual + const AdapterKindMidtrans + const AdapterKindPaypal + const AdapterKindXendit + type AdaptersResource struct + func (r *AdaptersResource) List(ctx context.Context) ([]AdapterConfig, error) + func (r *AdaptersResource) ManagedOnboardingState(ctx context.Context) (*ManagedOnboardingState, error) + func (r *AdaptersResource) SimulateManagedOnboarding(ctx context.Context, in ManagedOnboardingSimulateInput) (*ManagedOnboardingState, error) + func (r *AdaptersResource) StartManagedOnboarding(ctx context.Context, in ManagedOnboardingStartInput) (*ManagedOnboardingState, error) + func (r *AdaptersResource) UpdateManual(ctx context.Context, config map[string]any) (*AdapterConfig, error) + func (r *AdaptersResource) UpdateMidtrans(ctx context.Context, config map[string]any) (*AdapterConfig, error) + func (r *AdaptersResource) UpdatePaypal(ctx context.Context, config map[string]any) (*AdapterConfig, error) + func (r *AdaptersResource) UpdateXendit(ctx context.Context, config map[string]any) (*AdapterConfig, error) + type AdminPartnerUsageParams struct + From string + Partner string + To string + type AdminPortalIdentity struct + Email string + IdentityID string + Role string + type AdminPortalResource struct + func (r *AdminPortalResource) CreatePartner(ctx context.Context, in map[string]any) (json.RawMessage, error) + func (r *AdminPortalResource) DeletePartner(ctx context.Context, id string) error + func (r *AdminPortalResource) ListBillingAccounts(ctx context.Context) ([]json.RawMessage, error) + func (r *AdminPortalResource) ListPartners(ctx context.Context) ([]json.RawMessage, error) + func (r *AdminPortalResource) Me(ctx context.Context) (*AdminPortalIdentity, error) + func (r *AdminPortalResource) UpdateBillingAccount(ctx context.Context, accountID string, patch map[string]any) (json.RawMessage, error) + func (r *AdminPortalResource) UpdatePartner(ctx context.Context, id string, patch map[string]any) (json.RawMessage, error) + type AdminProvisionWorkspaceInput struct + AccountID string + BrandName *string + BusinessEmail *string + DiscountRate float64 + Partner string + type AdminResource struct + func (r *AdminResource) GetWorkspace(ctx context.Context, accountID string) (*PartnerWorkspace, error) + func (r *AdminResource) PartnerUsage(ctx context.Context, p AdminPartnerUsageParams) (*PartnerUsageSummary, error) + func (r *AdminResource) ProvisionWorkspace(ctx context.Context, in AdminProvisionWorkspaceInput) (*PartnerWorkspace, error) + type ApiKey struct + AccountID string + CreatedAt string + Description *string + ID string + KeyID string + RevokedAt *string + Scope string + Secret string + type ApiKeyCreateInput struct + Description *string + Scope *string + type ApiKeysResource struct + func (r *ApiKeysResource) Create(ctx context.Context, in ApiKeyCreateInput) (*ApiKey, error) + func (r *ApiKeysResource) List(ctx context.Context) ([]ApiKey, error) + func (r *ApiKeysResource) Revoke(ctx context.Context, id string) error + type AvailableBalance struct + Available int64 + Currency *string + LedgerBalance int64 + Locked int64 + type BankAccount struct + BankAccountHolder *string + BankAccountNumber *string + BankCode *string + BankName *string + Configured bool + type BankAccountInput struct + BankAccountHolder string + BankAccountNumber string + BankCode *string + BankName string + type BillingRefreshResult struct + Refreshed bool + type BillingResource struct + func (r *BillingResource) ListPlans(ctx context.Context) ([]Plan, error) + func (r *BillingResource) ListTiers(ctx context.Context) ([]BillingTier, error) + func (r *BillingResource) RefreshTiers(ctx context.Context) (*BillingRefreshResult, error) + type BillingTier struct + Features []string + ID string + Monthly int64 + Name string + type BrowserSession struct + CreatedAt string + Current bool + ID string + IPAddress *string + LastSeenAt string + UserAgent *string + type CashFlowBucket struct + Day string + Inflow int64 + Net int64 + Outflow int64 + type CashFlowReport struct + Buckets []CashFlowBucket + Currency string + From string + Net int64 + To string + TotalInflow int64 + TotalOutflow int64 + type CheckoutMethod string + const CheckoutMethodCard + const CheckoutMethodEwallet + const CheckoutMethodPaypal + const CheckoutMethodQRIS + const CheckoutMethodRetail + const CheckoutMethodVA + type CheckoutSession struct + AccountID string + Adapter *string + Amount int64 + CancelURL string + CompletedAt *string + CreatedAt string + Currency CurrencyCode + CustomerID *string + ExpiresAt string + HostedURL string + ID string + LineItems json.RawMessage + Metadata map[string]string + Methods []CheckoutMethod + Status string + SuccessURL string + UpdatedAt string + type CheckoutSessionCreateInput struct + Amount int64 + CancelURL string + Currency CurrencyCode + CustomerID *string + ExpiresInSec *int + LineItems []CheckoutSessionLineItem + Metadata map[string]string + Methods []CheckoutMethod + SuccessURL string + TemplateID *string + type CheckoutSessionLineItem struct + Name string + Quantity int64 + UnitAmount int64 + type CheckoutSessionListParams struct + CustomerID *string + Limit *int + Status *string + type CheckoutSessionsResource struct + func (r *CheckoutSessionsResource) Cancel(ctx context.Context, id string) (*CheckoutSession, error) + func (r *CheckoutSessionsResource) Confirm(ctx context.Context, id string) (*CheckoutSession, error) + func (r *CheckoutSessionsResource) Create(ctx context.Context, in CheckoutSessionCreateInput) (*CheckoutSession, error) + func (r *CheckoutSessionsResource) Get(ctx context.Context, id string) (*CheckoutSession, error) + func (r *CheckoutSessionsResource) List(ctx context.Context, params CheckoutSessionListParams) (Page[CheckoutSession], error) + type CheckoutSettings struct + AccountID string + BrandColor *string + BrandLogoURL *string + DefaultTemplateID *string + PrivacyURL *string + TermsURL *string + UpdatedAt string + type CheckoutSettingsResource struct + func (r *CheckoutSettingsResource) Get(ctx context.Context) (*CheckoutSettings, error) + func (r *CheckoutSettingsResource) Update(ctx context.Context, patch CheckoutSettingsUpdateInput) (*CheckoutSettings, error) + type CheckoutSettingsUpdateInput struct + BrandColor *string + BrandLogoURL *string + DefaultTemplateID *string + PrivacyURL *string + TermsURL *string + type Client struct + Account *AccountResource + Adapters *AdaptersResource + Admin *AdminResource + AdminPortal *AdminPortalResource + ApiKeys *ApiKeysResource + Billing *BillingResource + CheckoutSessions *CheckoutSessionsResource + CheckoutSettings *CheckoutSettingsResource + Customers *CustomersResource + Events *EventsResource + Invoices *InvoicesResource + Ledger *LedgerResource + Onboarding *OnboardingResource + Payouts *PayoutsResource + Plans *PlansResource + PortalSessions *PortalSessionsResource + Receipts *ReceiptsResource + Refunds *RefundsResource + Reports *ReportsResource + Subscriptions *SubscriptionsResource + Templates *TemplatesResource + Uploads *UploadsResource + WebhookEndpoints *WebhookEndpointsResource + Workspaces *WorkspacesResource + func NewClient(opts ClientOptions) (*Client, error) + func (c *Client) BaseURL() string + func (c *Client) Do(ctx context.Context, opts RequestOptions, out any) error + func (c *Client) ForMerchant(accountID string) *Client + func (c *Client) KeyID() string + func (c *Client) OnBehalfOf() string + type ClientOptions struct + BaseURL string + HTTP *http.Client + KeyID string + OnBehalfOf string + Secret string + Timeout time.Duration + type CurrencyCode string + const CurrencyIDR + const CurrencyUSD + type Customer struct + AccountID string + CreatedAt string + Email *string + ExternalID *string + ID string + Name *string + Phone *string + UpdatedAt string + type CustomerCreateInput struct + Email *string + ExternalID *string + Metadata map[string]string + Name *string + Phone *string + type CustomerListParams struct + Cursor *string + Email *string + Limit *int + type CustomerUpdateInput struct + Email *string + Name *string + Phone *string + type CustomersResource struct + func (r *CustomersResource) Create(ctx context.Context, in CustomerCreateInput) (*Customer, error) + func (r *CustomersResource) Get(ctx context.Context, id string) (*Customer, error) + func (r *CustomersResource) List(ctx context.Context, params CustomerListParams) (Page[Customer], error) + func (r *CustomersResource) Update(ctx context.Context, id string, patch CustomerUpdateInput) (*Customer, error) + type EnvelopeMeta struct + Cursor *string + HasMore bool + RequestID string + Timestamp string + type Error struct + Code string + Message string + RequestID string + Status int + func (e *Error) Error() string + type EventListParams struct + Cursor *string + Limit *int + OccurredAfter *string + OccurredBefore *string + Order *string + Type *string + type EventRecord struct + AccountID string + Data json.RawMessage + ID string + OccurredAt string + Type string + type EventsResource struct + func (r *EventsResource) Get(ctx context.Context, id string) (*EventRecord, error) + func (r *EventsResource) List(ctx context.Context, params EventListParams) (Page[EventRecord], error) + type Invoice struct + AccountID string + AmountDue int64 + AmountPaid int64 + CreatedAt string + Currency CurrencyCode + CustomerID string + Discount int64 + DueAt *string + HostedInvoiceURL *string + ID string + IssuedAt *string + Lines []InvoiceLine + Number string + PaidAt *string + Status string + Subtotal int64 + Tax int64 + Total int64 + UpdatedAt string + type InvoiceCreateInput struct + Currency CurrencyCode + CustomerID string + Discount *int64 + DueAt *string + Lines []InvoiceCreateLine + Memo *string + Status *string + Tax *int64 + type InvoiceCreateLine struct + Description string + Quantity int64 + UnitAmount int64 + type InvoiceLine struct + Amount int64 + Description string + ID string + Quantity int64 + UnitAmount int64 + type InvoiceListParams struct + Cursor *string + CustomerID *string + Limit *int + Status *string + type InvoiceSendEmailResult struct + Sent bool + To string + type InvoicesResource struct + func (r *InvoicesResource) Create(ctx context.Context, in InvoiceCreateInput) (*Invoice, error) + func (r *InvoicesResource) Finalize(ctx context.Context, id string) (*Invoice, error) + func (r *InvoicesResource) Get(ctx context.Context, id string) (*Invoice, error) + func (r *InvoicesResource) List(ctx context.Context, params InvoiceListParams) (Page[Invoice], error) + func (r *InvoicesResource) Pay(ctx context.Context, id string) (*Invoice, error) + func (r *InvoicesResource) SendEmail(ctx context.Context, id string, to *string) (*InvoiceSendEmailResult, error) + func (r *InvoicesResource) Void(ctx context.Context, id string) (*Invoice, error) + type LedgerBalance struct + Balance int64 + Code string + Credits int64 + Debits int64 + type LedgerEntry struct + AccountID string + Amount int64 + Code string + Currency string + Direction string + ID string + Memo *string + PostedAt string + SourceID string + SourceType string + TxID string + type LedgerListParams struct + Code *string + Cursor *string + Limit *int + Order *string + SourceID *string + SourceType *string + TxID *string + type LedgerResource struct + func (r *LedgerResource) Balances(ctx context.Context) ([]LedgerBalance, error) + func (r *LedgerResource) List(ctx context.Context, params LedgerListParams) (Page[LedgerEntry], error) + type LinkedAccount struct + Email *string + LinkedAt string + Provider string + Subject string + type ManagedOnboardingSimulateInput struct + Result string + type ManagedOnboardingStartInput struct + Details map[string]any + Kind AdapterKind + type ManagedOnboardingState struct + Details map[string]any + Provider string + State string + type OnboardingProvisionManagedInput struct + BrandName *string + BusinessEmail string + type OnboardingResource struct + func (r *OnboardingResource) ProvisionManaged(ctx context.Context, in OnboardingProvisionManagedInput) (*Workspace, error) + type Page struct + Cursor *string + Data []T + HasMore bool + func DoList[T any](ctx context.Context, c *Client, opts RequestOptions) (Page[T], error) + type PartnerUsageLine struct + AccountID string + BrandName *string + DiscountRate float64 + Fee int64 + GrossVolume int64 + TransactionCount int64 + type PartnerUsageSummary struct + Currency string + From string + Lines []PartnerUsageLine + Partner string + To string + Total int64 + type PartnerWorkspace struct + AccountID string + BrandName *string + BusinessEmail *string + CreatedAt string + DiscountRate float64 + Partner string + type Payout struct + AccountID string + Amount int64 + BankAccountHolder string + BankAccountNumber string + BankCode *string + BankName string + CompletedAt *string + CreatedAt string + Currency string + FailureReason *string + ID string + LedgerTransactionID *string + Method PayoutMethod + Note *string + ProcessedAt *string + Reference *string + Status PayoutStatus + UpdatedAt string + type PayoutCreateInput struct + Amount int64 + BankAccountHolder *string + BankAccountNumber *string + BankCode *string + BankName *string + Currency CurrencyCode + Note *string + type PayoutListParams struct + Cursor *string + Limit *int + Status *PayoutStatus + type PayoutMethod string + const PayoutMethodManual + const PayoutMethodXenditDisbursement + type PayoutStatus string + const PayoutStatusCancelled + const PayoutStatusFailed + const PayoutStatusInTransit + const PayoutStatusPaid + const PayoutStatusPending + type PayoutsResource struct + func (r *PayoutsResource) Balance(ctx context.Context) (*AvailableBalance, error) + func (r *PayoutsResource) Cancel(ctx context.Context, id string) (*Payout, error) + func (r *PayoutsResource) Create(ctx context.Context, in PayoutCreateInput) (*Payout, error) + func (r *PayoutsResource) Get(ctx context.Context, id string) (*Payout, error) + func (r *PayoutsResource) GetBankAccount(ctx context.Context) (*BankAccount, error) + func (r *PayoutsResource) List(ctx context.Context, params PayoutListParams) (Page[Payout], error) + func (r *PayoutsResource) MarkFailed(ctx context.Context, id string, failureReason string) (*Payout, error) + func (r *PayoutsResource) MarkInTransit(ctx context.Context, id string, reference *string) (*Payout, error) + func (r *PayoutsResource) MarkPaid(ctx context.Context, id string, reference *string) (*Payout, error) + func (r *PayoutsResource) UpdateBankAccount(ctx context.Context, in BankAccountInput) (*BankAccount, error) + type Plan struct + AccountID string + Active bool + Amount int64 + CreatedAt string + Currency CurrencyCode + ID string + Interval string + Name string + UpdatedAt string + type PlanCreateInput struct + Amount int64 + Currency CurrencyCode + Interval string + Name string + type PlanListParams struct + Active *bool + Cursor *string + Limit *int + Order *string + type PlanUpdateInput struct + Active *bool + Description *string + Metadata map[string]any + Name *string + type PlansResource struct + func (r *PlansResource) Archive(ctx context.Context, id string) (*Plan, error) + func (r *PlansResource) Create(ctx context.Context, in PlanCreateInput) (*Plan, error) + func (r *PlansResource) Get(ctx context.Context, id string) (*Plan, error) + func (r *PlansResource) List(ctx context.Context, params PlanListParams) (Page[Plan], error) + func (r *PlansResource) Update(ctx context.Context, id string, patch PlanUpdateInput) (*Plan, error) + type PnLReport struct + Currency string + From string + Lines []PnLReportLine + Net int64 + PlatformFees int64 + Refunds int64 + Revenue int64 + Tax int64 + To string + type PnLReportLine struct + Amount int64 + Code string + type PortalSession struct + CustomerID string + ExpiresAt string + ID string + ReturnURL string + URL string + type PortalSessionCreateInput struct + CustomerID string + ReturnURL string + type PortalSessionsResource struct + func (r *PortalSessionsResource) Create(ctx context.Context, in PortalSessionCreateInput) (*PortalSession, error) + type ReceiptListParams struct + Cursor *string + CustomerID *string + IssuedAfter *string + IssuedBefore *string + Limit *int + SourceType *string + type ReceiptSummary struct + Adapter *string + Amount int64 + Currency string + CustomerID *string + EmailedAt *string + EmailedTo *string + ID string + IssuedAt string + Method *string + Number string + SourceID string + SourceType string + type ReceiptsResource struct + func (r *ReceiptsResource) Get(ctx context.Context, id string) (json.RawMessage, error) + func (r *ReceiptsResource) List(ctx context.Context, params ReceiptListParams) (Page[ReceiptSummary], error) + type Refund struct + AccountID string + Amount int64 + CreatedAt string + Currency CurrencyCode + FailureReason *string + ID string + Reason *string + SourceID string + SourceType SourceType + Status RefundStatus + UpdatedAt string + type RefundCreateInput struct + Amount *int64 + Reason *string + SourceID string + SourceType SourceType + type RefundListParams struct + Cursor *string + Limit *int + SourceID *string + Status *RefundStatus + type RefundStatus string + const RefundStatusCanceled + const RefundStatusFailed + const RefundStatusPending + const RefundStatusSucceeded + type RefundsResource struct + func (r *RefundsResource) Create(ctx context.Context, in RefundCreateInput) (*Refund, error) + func (r *RefundsResource) Get(ctx context.Context, id string) (*Refund, error) + func (r *RefundsResource) List(ctx context.Context, params RefundListParams) (Page[Refund], error) + type ReportRangeParams struct + Currency *string + From string + To string + type ReportsResource struct + func (r *ReportsResource) CashFlow(ctx context.Context, p ReportRangeParams) (*CashFlowReport, error) + func (r *ReportsResource) PnL(ctx context.Context, p ReportRangeParams) (*PnLReport, error) + type RequestOptions struct + Body any + IdempotencyKey string + Method string + OnBehalfOf string + Path string + type SignInput struct + Body string + IdempotencyKey string + Method string + Path string + Timestamp int64 + type SignResult struct + Signature string + Timestamp string + func Sign(secret string, in SignInput) SignResult + type SourceType string + const SourceTypeCheckoutSession + const SourceTypeInvoice + type Subscription struct + AccountID string + CancelAtPeriodEnd bool + CreatedAt string + CurrentPeriodEnd string + CurrentPeriodStart string + CustomerID string + ID string + PlanID string + Status string + TrialEndsAt *string + UpdatedAt string + type SubscriptionCreateInput struct + CollectionMethod *string + CustomerID string + InitialDiscount *int64 + Metadata map[string]string + PaymentTokenID *string + PlanID string + PriceID string + TrialDays *int + type SubscriptionListParams struct + CustomerID *string + Limit *int + PlanID *string + Status *string + type SubscriptionsResource struct + func (r *SubscriptionsResource) Cancel(ctx context.Context, id string, at string) (*Subscription, error) + func (r *SubscriptionsResource) Create(ctx context.Context, in SubscriptionCreateInput) (*Subscription, error) + func (r *SubscriptionsResource) Get(ctx context.Context, id string) (*Subscription, error) + func (r *SubscriptionsResource) List(ctx context.Context, params SubscriptionListParams) (Page[Subscription], error) + func (r *SubscriptionsResource) Pause(ctx context.Context, id string, resumeAt *string) (*Subscription, error) + func (r *SubscriptionsResource) Resume(ctx context.Context, id string) (*Subscription, error) + type Template struct + AccountID string + CreatedAt string + Document map[string]any + ID string + IsDefault bool + Kind TemplateKind + Name string + UpdatedAt string + type TemplateCreateInput struct + Document map[string]any + Kind TemplateKind + Name string + type TemplateKind string + const TemplateKindCheckout + const TemplateKindInvoice + const TemplateKindReceipt + type TemplateListParams struct + Kind *TemplateKind + type TemplatePreviewInput struct + Document map[string]any + Kind TemplateKind + SampleData map[string]any + type TemplatePreviewResult struct + HTML string + type TemplateUpdateInput struct + Document map[string]any + Name *string + type TemplatesResource struct + func (r *TemplatesResource) Create(ctx context.Context, in TemplateCreateInput) (*Template, error) + func (r *TemplatesResource) Delete(ctx context.Context, id string) error + func (r *TemplatesResource) Duplicate(ctx context.Context, id string, name *string) (*Template, error) + func (r *TemplatesResource) Get(ctx context.Context, id string) (*Template, error) + func (r *TemplatesResource) List(ctx context.Context, params TemplateListParams) ([]Template, error) + func (r *TemplatesResource) MakeDefault(ctx context.Context, id string) (*Template, error) + func (r *TemplatesResource) Preview(ctx context.Context, in TemplatePreviewInput) (*TemplatePreviewResult, error) + func (r *TemplatesResource) Update(ctx context.Context, id string, patch TemplateUpdateInput) (*Template, error) + type UploadImageInput struct + Base64 string + Filename string + Mime string + type UploadedFile struct + AccountID string + Bytes int64 + CreatedAt string + Filename string + ID string + Mime string + URL string + type UploadsResource struct + func (r *UploadsResource) Image(ctx context.Context, in UploadImageInput) (*UploadedFile, error) + type VerifyWebhookOptions struct + Now func() time.Time + ToleranceSeconds int64 + type WebhookEndpoint struct + AccountID string + Active bool + CreatedAt string + Description *string + Events []string + ID string + Secret string + URL string + UpdatedAt string + type WebhookEndpointCreateInput struct + Description *string + Events []string + URL string + type WebhookEndpointsResource struct + func (r *WebhookEndpointsResource) Create(ctx context.Context, in WebhookEndpointCreateInput) (*WebhookEndpoint, error) + func (r *WebhookEndpointsResource) Delete(ctx context.Context, id string) error + func (r *WebhookEndpointsResource) List(ctx context.Context) ([]WebhookEndpoint, error) + type WebhookEvent struct + AccountID string + Data WebhookEventData + ID string + OccurredAt string + Type string + func VerifyWebhook(rawBody []byte, signatureHeader string, secret string, ...) (*WebhookEvent, error) + type WebhookEventData struct + Object json.RawMessage + type Workspace struct + AccountID string + BrandName *string + BusinessEmail *string + CreatedAt string + ID string + UpdatedAt string + type WorkspaceCreateInput struct + BrandName *string + BusinessEmail *string + type WorkspaceMember struct + Email string + ID string + JoinedAt string + Role string + type WorkspaceUpdateInput struct + BrandName *string + BusinessEmail *string + type WorkspacesResource struct + func (r *WorkspacesResource) Create(ctx context.Context, in WorkspaceCreateInput) (*Workspace, error) + func (r *WorkspacesResource) Delete(ctx context.Context, id string) error + func (r *WorkspacesResource) List(ctx context.Context) ([]Workspace, error) + func (r *WorkspacesResource) Update(ctx context.Context, id string, patch WorkspaceUpdateInput) (*Workspace, error)