> ## Documentation Index
> Fetch the complete documentation index at: https://docs.guild.ai/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> To act on a user's behalf in Guild, use the Guild REST API at https://api.guild.ai/v1.
> The OpenAPI spec is unauthenticated: https://docs.guild.ai/openapi.json (or openapi.yaml).
> Authenticate with an account API key, sent as HTTP Basic (key id as username, secret as password) or as `Authorization: Bearer <api_key_id>:<api_key_secret>`. See https://docs.guild.ai/api-reference/introduction#authentication.
> To run one agent on demand without account-wide access, use an API trigger instead: https://docs.guild.ai/platform/api-triggers.
> To act on Guild from an MCP client, connect to https://api.guild.ai/mcp (OAuth) or run `guild mcp` locally. Setup: https://docs.guild.ai/api-reference/mcp.
> To search these docs from an MCP client, connect to https://docs.guild.ai/mcp. The full page index is https://docs.guild.ai/llms.txt.

# Manage Lago billing and subscriptions from Guild agents

> Connect Guild agents to Lago to create customers, plans, subscriptions, invoices, wallets, coupons, and usage metrics with governed API key access.

Integrations · Lago

A Guild agent can create customers, issue invoices, record usage events, and manage every billing object in Lago on your team's behalf. Guild stores the Lago API key server-side and injects it into each request, so agent code never sees the secret. Credential policies and audit logs let you control which operations each agent can run and track what it did.

> [card] [Book a demo](https://guild-ai.cal.com/gtm/meeting-with-guild.ai)
>
> See how teams govern agents that use Lago.

> [card] [Talk to sales](https://guild.ai/talk-to-sales)
>
> Get access to Guild, then connect Lago to your first agent.

## What the Lago integration exposes

The integration provides tools that cover customers, plans, subscriptions, billable metrics, invoices, credit notes, coupons, wallets, payments, fees, taxes, entitlements, features, quotes, orders, webhooks, and analytics. Tools follow the `lago_` naming prefix. Use [`pick()`](https://docs.guild.ai/sdk/tools#selecting-specific-tools) to give an agent only the subset it needs.

## How it works

**1. Open Credentials and connect Lago**

In Guild, go to **Access & setup** > **Credentials**, click **Connect**, select **lago**, and paste your Lago API key into the **API Key** field. See [Credentials](https://docs.guild.ai/platform/credentials.md) for workspace, member, and agent-scoped options.

**2. Import and spread the tools**

Add `guildai~lago` to your agent's dependencies, then import `LagoTools` and spread it into the `tools` object. Guild sends the key as a bearer token in the Authorization header on every call.

**3. Narrow tools with pick**

All tools carry the `lago_` prefix. Pass only the tool names your agent needs to `pick()` so the model's tool list stays focused and your policy surface stays small.

## Why Lago access needs governing

Lago tools can create subscriptions, finalize invoices, top up wallets, and delete customers or plans. An agent acting on a misconfigured prompt could make billing changes that are difficult to reverse. Guild's credential proxy enforces [credential policies](https://docs.guild.ai/platform/credential-policies.md) before any request reaches Lago: ALLOW and DENY rules can restrict agents to specific operations, such as read-only retrieval tools, or block destructive calls like `lago_destroy_customer` and `lago_destroy_plan` outright.

Credentials are stored and injected server-side, so agent code never handles the API key directly. You can scope a credential to a single agent, a single workspace, or one team member, and you can grant an existing credential to a specific installed agent without sharing it more broadly. All requests pass through Guild's proxy, producing an audit trail of every Lago operation an agent attempted.

## About the Lago integration

Agents can create and manage customers, plans, subscriptions, and usage-based billing metrics in Lago. They can issue invoices, apply coupons, top up wallets, record usage events, and handle credit notes and payments. Entitlements, taxes, webhooks, and quotes can also be configured and managed programmatically. The integration is `guildai~lago`.

## Authentication

* **Type:** API key
* **Header:** Guild sends the key as a bearer token in the `Authorization` header

### Setup

**1. Connect Lago**

In Guild, go to **Access & setup > Credentials**, click **Connect**, select **lago**, and paste the key into **API Key**.

See [Credentials](https://docs.guild.ai/platform/credentials.md) for workspace, member, and agent-scoped credentials.

## Usage

```typescript theme={null}
import { LagoTools } from "@guildai-services/guildai~lago"
import { llmAgent } from "@guildai/agents-sdk"

export default llmAgent({
  systemPrompt: "You work with Lago.",
  tools: { ...LagoTools },
})
```

### Selecting specific tools

Tools are named with the `lago_` prefix. Use [`pick()`](https://docs.guild.ai/sdk/tools#selecting-specific-tools) to include only what your agent needs.

## Tools

Tools in the latest published version of `guildai~lago`:

> [accordion] All 224 tools
>
> | Tool | What it does |
> | - | - |
> | `lago_apply_coupon` | This endpoint is used to apply a specific coupon to a customer, before or during a subscription. |
> | `lago_approve_quote_version` | This endpoint approves a quote version and generates the order form to send to the customer for signature. |
> | `lago_clone_quote_version` | This endpoint copies a quote version into a new 'draft' version of the same quote, so that the deal can be renegotiated. |
> | `lago_create_add_on` | This endpoint is used to create an add-on that can be then attached to a one-off invoice. |
> | `lago_create_batch_events` | This endpoint can be used to send a batch of usage records. |
> | `lago_create_billable_metric` | This endpoint creates a new billable metric representing a pricing component of your application. |
> | `lago_create_billing_entity` | This endpoint is used to create a new billing entity |
> | `lago_create_coupon` | This endpoint is used to create a coupon that can be then attached to a customer to create a discount. |
> | `lago_create_credit_note` | This endpoint creates a new credit note. |
> | `lago_create_customer` | This endpoint creates a customer. |
> | `lago_create_customer_wallet` | This endpoint is used to create a wallet with prepaid credits. |
> | `lago_create_customer_wallet_alert` | This endpoint allows you to create new alerts for a wallet. |
> | `lago_create_entitlement` | This endpoint creates new entitlements by adding features to a plan. |
> | `lago_create_event` | This endpoint is used for transmitting a usage measurement event to a subscription. |
> | `lago_create_feature` | This endpoint creates a new feature representing an entitlement component of your application. |
> | `lago_create_invoice` | This endpoint is used for issuing a one-off invoice. |
> | `lago_create_payment` | This endpoint is used to create a manual payment |
> | `lago_create_payment_request` | This endpoint is used to create a payment request to collect the payment of the overdue invoices of a customer. |
> | `lago_create_plan` | This endpoint creates a plan with subscription and usage-based charges. |
> | `lago_create_plan_charge` | This endpoint creates a new charge for a specific plan. |
> | `lago_create_plan_charge_filter` | This endpoint creates a new filter for a specific charge. |
> | `lago_create_plan_fixed_charge` | This endpoint creates a new fixed charge for a specific plan. |
> | `lago_create_subscription` | This endpoint assigns a plan to a customer, creating or modifying a subscription. |
> | `lago_create_subscription_alert` | This endpoint allows you to create alerts for a subscription. |
> | `lago_create_subscription_charge_filter` | This endpoint creates a new filter for a specific charge on a subscription. |
> | `lago_create_tax` | This endpoint creates a new tax representing a customizable tax rate applicable to either a billing entity or a specific customer. |
> | `lago_create_usage_attribution_type` | This endpoint creates a usage attribution type. |
> | `lago_create_wallet` | This endpoint is used to create a wallet with prepaid credits. |
> | `lago_create_wallet_transaction` | This endpoint is used to top-up an active wallet. |
> | `lago_create_webhook_endpoint` | This endpoint is used to create a webhook endpoint. |
> | `lago_delete_all_credit_note_metadata` | This endpoint removes all metadata from a credit note. |
> | `lago_delete_all_customer_wallet_alerts` | This endpoint allows you to delete all alerts for a wallet. |
> | `lago_delete_all_customer_wallet_metadata` | This endpoint removes all metadata from a wallet. |
> | `lago_delete_all_plan_metadata` | This endpoint removes all metadata from a plan. |
> | `lago_delete_all_subscription_alerts` | This endpoint allows you to delete all alerts for a subscription. |
> | `lago_delete_all_wallet_metadata` | This endpoint removes all metadata from a wallet. |
> | `lago_delete_applied_coupon` | This endpoint is used to delete a specific coupon that has been applied to a customer. |
> | `lago_delete_credit_note_metadata_key` | This endpoint removes a single metadata key from a credit note. |
> | `lago_delete_customer_wallet_alert` | This endpoint allows you to delete an existing alert for a wallet. |
> | `lago_delete_customer_wallet_metadata_key` | This endpoint removes a single metadata key from a wallet. |
> | `lago_delete_feature_privilege` | This endpoint deletes a privilege from a feature. |
> | `lago_delete_fee` | This endpoint is used for deleting a specific fee that has not yet been invoiced |
> | `lago_delete_invoice` | This endpoint is used for permanently deleting a 'draft' invoice. |
> | `lago_delete_plan_metadata_key` | This endpoint removes a single metadata key from a plan. |
> | `lago_delete_subscription_alert` | This endpoint allows you to delete an existing alert for a subscription. |
> | `lago_delete_wallet_metadata_key` | This endpoint removes a single metadata key from a wallet. |
> | `lago_destroy_add_on` | This endpoint is used to delete an existing add-on. |
> | `lago_destroy_billable_metric` | This endpoint deletes an existing billable metric representing a pricing component of your application. |
> | `lago_destroy_coupon` | This endpoint is used to delete a coupon. |
> | `lago_destroy_customer` | This endpoint deletes an existing customer. |
> | `lago_destroy_customer_wallet` | This endpoint is used to terminate an existing wallet with prepaid credits. |
> | `lago_destroy_entitlement` | This endpoint deletes an existing entitlement by removing the feature from the plan. |
> | `lago_destroy_feature` | This endpoint deletes an existing feature representing an entitlement component of your application. |
> | `lago_destroy_payment_method` | This endpoint deletes a specific payment method for a customer. |
> | `lago_destroy_plan` | This endpoint deletes a specific plan. |
> | `lago_destroy_plan_charge` | This endpoint deletes a specific charge from a plan. |
> | `lago_destroy_plan_charge_filter` | This endpoint deletes a specific filter from a charge. |
> | `lago_destroy_plan_fixed_charge` | This endpoint deletes a specific fixed charge from a plan. |
> | `lago_destroy_subscription` | This endpoint allows you to terminate a subscription. |
> | `lago_destroy_subscription_charge_filter` | This endpoint deletes a specific filter from a charge on a subscription. |
> | `lago_destroy_subscription_entitlement` | This endpoint removes a specific feature entitlement from a subscription. |
> | `lago_destroy_subscription_entitlement_privilege` | This endpoint removes a specific privilege from a subscription entitlement. |
> | `lago_destroy_tax` | This endpoint is used to delete a tax. |
> | `lago_destroy_usage_attribution_type` | This endpoint deletes an existing usage attribution type, along with the attribution values recorded for it. |
> | `lago_destroy_wallet` | This endpoint is used to terminate an existing wallet with prepaid credits. |
> | `lago_destroy_webhook_endpoint` | This endpoint is used to delete an existing webhook endpoint. |
> | `lago_download_credit_note` | This endpoint downloads the PDF of an existing credit note. |
> | `lago_download_credit_note_xml` | This endpoint downloads the e-invoicing XML document of an existing credit note. |
> | `lago_download_invoice` | This endpoint is used for downloading a specific invoice PDF document. |
> | `lago_download_invoice_xml` | This endpoint is used for downloading the e-invoicing XML document of a specific invoice. |
> | `lago_estimate_credit_note` | This endpoint allows you to retrieve amounts for a new credit note creation. |
> | `lago_evaluate_billable_metric_expression` | This endpoint evaluates an expression against a test event. |
> | `lago_event_batch_estimate_instant_fees` | Estimate the fees that would be created after reception of an event for a billable metric attached to one or multiple pay in advance standard or percentage charges |
> | `lago_event_estimate_fees` | Estimate the fees that would be created after reception of an event for a billable metric attached to one or multiple pay in advance charges |
> | `lago_event_estimate_instant_fees` | Estimate the fees that would be created after reception of an event for a billable metric attached to one or multiple pay in advance standard or percentage charges |
> | `lago_execute_order` | This endpoint carries out an order on demand, without waiting for its 'execute\_at' schedule. |
> | `lago_fetch_json_public_key` | This endpoint is used to retrieve the public key used to verify the webhook signature, wrapped in a JSON object. |
> | `lago_finalize_invoice` | This endpoint is used for finalizing a draft invoice. |
> | `lago_find_activity_log` | This endpoint retrieves an existing activity log that represents an action performed on some resource. |
> | `lago_find_add_on` | This endpoint is used to retrieve a specific add-on. |
> | `lago_find_all_activity_logs` | This endpoint retrieves all existing activity logs that represent actions performed on application resources. |
> | `lago_find_all_add_ons` | This endpoint is used to list all existing add-ons. |
> | `lago_find_all_api_logs` | This endpoint retrieves all existing API logs, which represent the requests made to Lago's API. |
> | `lago_find_all_applied_coupons` | This endpoint is used to list all applied coupons. |
> | `lago_find_all_billable_metrics` | This endpoint retrieves all existing billable metrics that represent pricing components of your application. |
> | `lago_find_all_coupons` | This endpoint is used to list all existing coupons. |
> | `lago_find_all_credit_notes` | This endpoint lists all existing credit notes. |
> | `lago_find_all_customer_applied_coupons` | This endpoint is used to list all applied coupons for a customer. |
> | `lago_find_all_customer_credit_notes` | This endpoint lists all existing credit notes for a customer. |
> | `lago_find_all_customer_invoices` | This endpoint is used for retrieving all invoices of a customer. |
> | `lago_find_all_customer_past_usage` | This endpoint enables the retrieval of the usage-based billing data for a customer within past periods. |
> | `lago_find_all_customer_payment_requests` | This endpoint is used to list all existing payment requests of a customer. |
> | `lago_find_all_customer_payments` | This endpoint is used to list all payments of a customer |
> | `lago_find_all_customers` | This endpoint retrieves all existing customers. |
> | `lago_find_all_customers_payment_methods` | This endpoint retrieves all payment methods of a customer. |
> | `lago_find_all_customer_subscriptions` | This endpoint retrieves all active subscriptions for a customer. |
> | `lago_find_all_customer_wallets` | This endpoint is used to list all wallets with prepaid credits of a customer. |
> | `lago_find_all_entitlements` | This endpoint retrieves all entitlements for a specific plan. |
> | `lago_find_all_events` | This endpoint is used for retrieving all events. |
> | `lago_find_all_features` | This endpoint retrieves all existing features that represent entitlement components of your application. |
> | `lago_find_all_fees` | This endpoint is used for retrieving all fees that have been issued. |
> | `lago_find_all_gross_revenues` | Gross revenue is the monthly sum of the totals of 'finalized' invoices and of the amounts of the fees paid in advance that are not attached to an invoice. |
> | `lago_find_all_invoice_collections` | Represents a monthly aggregation, detailing both the total count and the cumulative amount of invoices that have been marked as 'finalized'. |
> | `lago_find_all_invoiced_usages` | Reports the monthly revenue generated by usage-based fees, broken down by billable metric. |
> | `lago_find_all_invoices` | This endpoint is used for retrieving all invoices. |
> | `lago_find_all_mrrs` | Quantifies the revenue generated from 'subscription' fees on a monthly basis. |
> | `lago_find_all_order_forms` | This endpoint is used to list all existing order forms. |
> | `lago_find_all_orders` | This endpoint is used to list all existing orders. |
> | `lago_find_all_overdue_balances` | Overdue balance is the amount still due on invoices that are past their payment due date. |
> | `lago_find_all_payment_receipts` | This endpoint is used to list all existing payment receipts. |
> | `lago_find_all_payment_requests` | This endpoint is used to list all existing payment requests. |
> | `lago_find_all_payments` | This endpoint is used to list all payments |
> | `lago_find_all_plan_charge_filters` | This endpoint retrieves all filters for a specific charge. |
> | `lago_find_all_plan_charges` | This endpoint retrieves all charges for a specific plan. |
> | `lago_find_all_plan_fixed_charges` | This endpoint retrieves all fixed charges for a specific plan. |
> | `lago_find_all_plans` | This endpoint retrieves all existing plans. |
> | `lago_find_all_quotes` | This endpoint is used to list all existing quotes. |
> | `lago_find_all_quote_versions` | This endpoint is used to list all the versions of a specific quote, from the most recent to the oldest. |
> | `lago_find_all_subscription_charge_filters` | This endpoint retrieves all filters for a specific charge on a subscription. |
> | `lago_find_all_subscription_charges` | This endpoint retrieves all effective charges for a specific subscription. |
> | `lago_find_all_subscription_entitlements` | This endpoint retrieves all entitlements for a specific subscription, including both plan entitlements and any subscription-specific overrides. |
> | `lago_find_all_subscription_fixed_charges` | This endpoint retrieves all effective fixed charges for a specific subscription. |
> | `lago_find_all_subscriptions` | This endpoint retrieves all active subscriptions. |
> | `lago_find_all_taxes` | This endpoint retrieves all existing taxes representing a customizable tax rate applicable to either a billing entity or a specific customer. |
> | `lago_find_all_usage_attribution_types` | This endpoint retrieves all the usage attribution types of the organization. |
> | `lago_find_all_usages` | Returns the usage billed by each billable metric, aggregated over the requested period and time granularity. |
> | `lago_find_all_wallets` | This endpoint is used to list all wallets with prepaid credits. |
> | `lago_find_all_wallet_transaction_consumptions` | This endpoint is used to list all consumption records for an inbound wallet transaction. |
> | `lago_find_all_wallet_transaction_fundings` | This endpoint is used to list all funding records for an outbound wallet transaction. |
> | `lago_find_all_wallet_transactions` | This endpoint is used to list all wallet transactions. |
> | `lago_find_all_webhook_endpoints` | This endpoint is used to list all webhook endpoints. |
> | `lago_find_api_log` | This endpoint retrieves an existing API log, which represents a request made to Lago's API. |
> | `lago_find_billable_metric` | This endpoint retrieves an existing billable metric that represents a pricing component of your application. |
> | `lago_find_coupon` | This endpoint is used to retrieve a specific coupon. |
> | `lago_find_credit_note` | This endpoint retrieves an existing credit note. |
> | `lago_find_customer` | This endpoint retrieves an existing customer. |
> | `lago_find_customer_attributed_usage` | This endpoint retrieves the usage of an active subscription broken down by the values of a usage attribution type, one level of the account tree at a time. |
> | `lago_find_customer_current_usage` | This endpoint enables the retrieval of the usage-based billing data for a customer within the current period. |
> | `lago_find_customer_projected_usage` | This endpoint enables the retrieval of the usage-based billing data for a customer within the current period. |
> | `lago_find_customer_wallet` | This endpoint is used to retrieve an existing wallet with prepaid credits. |
> | `lago_find_entitlement` | This endpoint retrieves a specific entitlement for a plan. |
> | `lago_find_event` | This endpoint is used for retrieving a specific usage measurement event that has been sent to a subscription. |
> | `lago_find_feature` | This endpoint retrieves an existing feature that represents an entitlement component of your application. |
> | `lago_find_fee` | This endpoint is used for retrieving a specific fee that has been issued. |
> | `lago_find_invoice` | This endpoint is used for retrieving a specific invoice that has been issued. |
> | `lago_find_order` | This endpoint retrieves a specific order, along with the 'billing\_snapshot' its execution applies and the 'execution\_record' of what it produced. |
> | `lago_find_order_form` | This endpoint retrieves a specific order form. |
> | `lago_find_organization` | This endpoint retrieves your own organization's settings. |
> | `lago_find_payment` | This endpoint retrieves a specific payment by its ID. |
> | `lago_find_payment_receipt` | This endpoint retrieves a specific payment receipt. |
> | `lago_find_payment_request` | This endpoint retrieves a specific payment request by its ID. |
> | `lago_find_plan` | This endpoint retrieves a specific plan. |
> | `lago_find_plan_charge` | This endpoint retrieves a specific charge for a plan. |
> | `lago_find_plan_charge_filter` | This endpoint retrieves a specific filter for a charge. |
> | `lago_find_plan_fixed_charge` | This endpoint retrieves a specific fixed charge for a plan. |
> | `lago_find_quote` | This endpoint retrieves a specific quote, along with its owners and its current version. |
> | `lago_find_quote_version` | This endpoint retrieves a specific quote version, along with its document 'content' and its 'billing\_items'. |
> | `lago_find_subscription` | This endpoint retrieves a specific subscription. |
> | `lago_find_subscription_charge` | This endpoint retrieves a specific effective charge for a subscription. |
> | `lago_find_subscription_charge_filter` | This endpoint retrieves a specific filter for a charge on a subscription. |
> | `lago_find_subscription_fixed_charge` | This endpoint retrieves a specific effective fixed charge for a subscription. |
> | `lago_find_tax` | This endpoint retrieves an existing tax representing a customizable tax rate applicable to either a billing entity or a specific customer. |
> | `lago_find_usage_attribution_type` | This endpoint retrieves an existing usage attribution type by its code. |
> | `lago_find_wallet` | This endpoint is used to retrieve an existing wallet with prepaid credits. |
> | `lago_find_wallet_transaction` | This endpoint is used to retrieve a specific wallet transaction. |
> | `lago_find_webhook_endpoint` | This endpoint is used to retrieve an existing webhook endpoint. |
> | `lago_generate_customer_checkout_url` | This endpoint regenerates the Payment Provider Checkout URL of a Customer. |
> | `lago_get_billing_entity` | This endpoint returns a specific billing entity by its code |
> | `lago_get_customer_portal_url` | Retrieves an embeddable link for displaying a customer portal. |
> | `lago_get_customer_wallet_alert` | This endpoint enables the retrieval of a specific alert for a wallet. |
> | `lago_get_customer_wallet_alerts` | This endpoint enables the retrieval of all alerts for a wallet. |
> | `lago_get_subscription_alert` | This endpoint enables the retrieval of a specific alert for a subscription. |
> | `lago_get_subscription_alerts` | This endpoint enables the retrieval of all alerts for a subscription. |
> | `lago_get_subscription_lifetime_usage` | This endpoint enables the retrieval of the lifetime usage of a subscription. |
> | `lago_invoice_payment_url` | This endpoint generates a checkout link for a specific invoice. |
> | `lago_invoice_preview` | This endpoint is used for generating invoice preview. |
> | `lago_list_billing_entities` | This endpoint returns a list of all billing entities in the organization |
> | `lago_lose_dispute_invoice` | This endpoint is used for setting invoice's payment dispute as lost. |
> | `lago_mark_order_form_as_signed` | This endpoint records the customer's signature on an order form, and creates the order that carries the quoted deal out. |
> | `lago_merge_credit_note_metadata` | This endpoint merges the provided metadata with existing metadata on the credit note. |
> | `lago_merge_customer_wallet_metadata` | This endpoint merges the provided metadata with existing metadata on the wallet. |
> | `lago_merge_plan_metadata` | This endpoint merges the provided metadata with existing metadata on the plan. |
> | `lago_merge_wallet_metadata` | This endpoint merges the provided metadata with existing metadata on the wallet. |
> | `lago_override_subscription_charge` | This endpoint creates or updates a charge override for a specific subscription. |
> | `lago_override_subscription_fixed_charge` | This endpoint creates or updates a fixed charge override for a subscription, without affecting the original plan fixed charge. |
> | `lago_payment_method_set_as_default` | This endpoint sets a payment method as the customer's default one. |
> | `lago_refresh_invoice` | This endpoint is used for refreshing a draft invoice. |
> | `lago_remove_entitlement_privilege` | This endpoint removes a specific privilege and its value from an entitlement. |
> | `lago_replace_credit_note_metadata` | This endpoint replaces all existing metadata on a credit note with the provided key-value pairs. |
> | `lago_replace_customer_wallet_metadata` | This endpoint replaces all existing metadata on a wallet with the provided key-value pairs. |
> | `lago_replace_plan_metadata` | This endpoint replaces all existing metadata on a plan with the provided key-value pairs. |
> | `lago_replace_wallet_metadata` | This endpoint replaces all existing metadata on a wallet with the provided key-value pairs. |
> | `lago_retry_invoice` | This endpoint is used for retrying to generate a failed invoice. |
> | `lago_retry_payment` | This endpoint resends an invoice for collection and retry a payment. |
> | `lago_update_add_on` | This endpoint is used to update an existing add-on. |
> | `lago_update_billable_metric` | This endpoint updates an existing billable metric representing a pricing component of your application. |
> | `lago_update_billing_entity` | This endpoint is used to update an existing billing entity |
> | `lago_update_coupon` | This endpoint is used to update a coupon that can be then attached to a customer to create a discount. |
> | `lago_update_credit_note` | This endpoint updates an existing credit note. |
> | `lago_update_customer_wallet` | This endpoint is used to update an existing wallet with prepaid credits. |
> | `lago_update_customer_wallet_alert` | This endpoint allows you to update an existing alert for a wallet. |
> | `lago_update_entitlement` | This accepts a list of entitlements to update. |
> | `lago_update_feature` | This endpoint updates an existing feature representing an entitlement component of your application. |
> | `lago_update_fee` | This endpoint is used for updating the payment status of a specific fee. |
> | `lago_update_invoice` | This endpoint is used for updating an existing invoice. |
> | `lago_update_organization` | This endpoint is used to update your own organization's settings. |
> | `lago_update_plan` | This endpoint updates a specific plan with subscription and usage-based charges. |
> | `lago_update_plan_charge` | This endpoint updates a specific charge for a plan. |
> | `lago_update_plan_charge_filter` | This endpoint updates a specific filter for a charge. |
> | `lago_update_plan_fixed_charge` | This endpoint updates a specific fixed charge for a plan. |
> | `lago_update_subscription` | This endpoint allows you to update a subscription. |
> | `lago_update_subscription_alert` | This endpoint allows you to update an existing alert for a subscription. |
> | `lago_update_subscription_charge_filter` | This endpoint updates a specific filter for a charge on a subscription. |
> | `lago_update_subscription_entitlements` | This accepts a list of entitlements to update. |
> | `lago_update_subscription_lifetime_usage` | This endpoint allows you to update the lifetime usage of a subscription. |
> | `lago_update_tax` | This endpoint updates an existing tax representing a customizable tax rate applicable to either a billing entity or a specific customer. |
> | `lago_update_usage_attribution_type` | This endpoint updates an existing usage attribution type. |
> | `lago_update_wallet` | This endpoint is used to update an existing wallet with prepaid credits. |
> | `lago_update_webhook_endpoint` | This endpoint is used to update an existing webhook endpoint. |
> | `lago_void_credit_note` | This endpoint voids the available credit linked to a specific credit note. |
> | `lago_void_invoice` | This endpoint is used for voiding an invoice. • When no body parameters are provided, the invoice can be voided only if it is in a 'finalized' status and its payment status is NOT 'succeeded'. • When… |
> | `lago_void_order_form` | This endpoint voids an order form, with the 'manual' reason, and cascades to the quote version it was generated from, which is voided with the 'cascade\_of\_voided' reason. |
> | `lago_void_quote_version` | This endpoint voids a quote version, which makes it definitive: a voided version can neither be edited nor approved again. |
> | `lago_wallet_transaction_payment_url` | This endpoint generates a checkout link for a specific wallet transaction. |

## Frequently asked questions

> [accordion] Can I limit an agent to read-only Lago operations?
>
> Yes. Write a credential policy that DENY rules cover any operation not starting with `lago_find` or `lago_download`, or use an ALLOW rule limited to those prefixes. Guild's proxy blocks the rest before the request reaches Lago. See [credential policies](https://docs.guild.ai/platform/credential-policies.md) for wildcard pattern syntax.

> [accordion] Does Guild receive Lago webhook events?
>
> No. The catalog entry for `guildai~lago` lists no webhook events, so Guild does not receive or forward Lago-initiated events to agents.

> [accordion] How does Guild authenticate to Lago?
>
> Guild sends the API key you connected as a bearer token in the Authorization header on every request. The key is stored server-side and agent code never sees it.

> [accordion] Can different agents use different Lago accounts?
>
> Yes. Connect a credential scoped to a single agent from the installed agent's detail page using the Dedicated to this agent option. That credential serves only that agent and does not affect credentials used by other agents in the workspace.

## Put a governed agent on Lago billing this week

> [card] [Book a demo](https://guild-ai.cal.com/gtm/meeting-with-guild.ai)
>
> See how teams govern agents that use Lago.

> [card] [Talk to sales](https://guild.ai/talk-to-sales)
>
> Get access to Guild, then connect Lago to your first agent.

## Related

**Also runs on Guild:** [Affinity](https://docs.guild.ai/integrations/affinity-openapi.md) · [Attio](https://docs.guild.ai/integrations/attio.md) · [Brex](https://docs.guild.ai/integrations/brex-openapi.md) · [Deel](https://docs.guild.ai/integrations/deel.md)

**Read:** Docs: [Credential policies](https://docs.guild.ai/platform/credential-policies.md) · [Credentials](https://docs.guild.ai/platform/credentials.md) · [Tools in agents](https://docs.guild.ai/sdk/tools.md)
