KosmoKrator

payments

PayPal CLI for Coding Agents

Use the PayPal CLI for coding agents with headless JSON commands, schema discovery, credentials, and permission controls.

7 functions 6 read 1 write Bearer token auth

PayPal CLI for Coding Agents

Let coding agents discover schemas and execute integration functions through CLI commands or MCP.

Use this pattern when another coding agent needs exact commands and schema discovery. The PayPal CLI uses the same integration registry as the TUI, Lua runtime, and MCP gateway, but returns predictable command output for automation.

Command Shape

# PayPal CLI for Coding Agents
kosmokrator integrations:configure paypal --set access_token="$PAYPAL_ACCESS_TOKEN" --enable --read allow --write ask --json
kosmo integrations:call paypal.paypal_list_orders '{"page_size":1,"start_id":"example_start_id","start_time":"example_start_time","end_time":"example_end_time","status":"example_status"}' --json

Discovery Before Execution

Agents and scripts can inspect PayPal docs and schemas before choosing a function.

kosmo integrations:docs paypal --json
kosmo integrations:docs paypal.paypal_list_orders --json
kosmo integrations:schema paypal.paypal_list_orders --json
kosmo integrations:search "PayPal" --json
kosmo integrations:list --json

Useful PayPal CLI Functions

FunctionTypeParametersDescription
paypal.paypal_list_orders Read page_size, start_id, start_time, end_time, status List PayPal checkout orders. Returns order IDs, statuses, and amounts. Use filters to narrow results by status or date range.
paypal.paypal_get_order Read order_id Get details of a specific PayPal checkout order by its order ID. Returns full order information including status, payer details, and line items.
paypal.paypal_create_order Write intent, purchase_units, payer, payment_source Create a new PayPal checkout order. Specify the intent, purchase units with amounts, and optional payer details. Returns the created order with approval links.
paypal.paypal_list_payments Read count, start_id, start_time, end_time, sort_by, sort_order List PayPal payments. Returns payment IDs, states, amounts, and transaction details. Use filters to narrow results by count or date range.
paypal.paypal_get_payment Read payment_id Get details of a specific PayPal payment by its payment ID. Returns full payment information including state, amount, payer details, and transactions.
paypal.paypal_list_invoices Read page, page_size, total_required, fields List PayPal invoices. Returns invoice IDs, numbers, statuses, amounts, and recipient details. Use pagination parameters to navigate through results.
paypal.paypal_get_current_user Read schema Get the authenticated PayPal user's profile information. Returns the user's name, email, and other account details.

Automation Notes

Related PayPal CLI Pages