Faturação
O plano, o pagamento por utilização, as faturas e as ligações para pagar.
Ferramentas de faturação
| Ferramenta | O que faz |
|---|---|
| getBilling | O plano do espaço de trabalho e o que inclui, como Planos e faturação o mostra: como é faturado, quando se renova ou termina e a próxima cobrança, os domínios, os envios deste mês, as ações de IA de hoje e o pagamento por utilização. |
| listBillingPlans | Cada plano, do mais barato para o mais caro, com o seu preço, onde é vendido e o que inclui. |
| getBillingUsage | Os envios e as ações de IA por dia, e o que custam por mês os extras do pagamento por utilização, como os gráficos de Utilização os mostram. days recua até 3660 dias, e all até ao dia em que o espaço de trabalho foi criado. |
| listBillingAlerts | O que o aviso de faturação da app diria agora, o mais urgente primeiro. |
| listBillingCountries | Cada código de país que uma morada de faturação aceita. |
| getPayAsYouGo | Pagamento por utilização: se os extras são faturados, o limite mensal e o que custam até agora, o período atual, os limites que se podem escolher e os preços. |
| setPayAsYouGo | Ativar ou desativar o pagamento por utilização. Da primeira vez devolve uma ligação onde a pessoa adiciona um cartão. No chat da app pergunta sempre primeiro. |
| setPayAsYouGoLimit | Definir o limite mensal do pagamento por utilização. No chat da app pergunta sempre primeiro. |
| confirmPayAsYouGo | Depois de a pessoa adicionar o cartão, verificar que foi guardado e registá-lo. No chat da app pergunta sempre primeiro. |
| startPlanCheckout | A ligação para um pagamento de um plano pago, para um espaço de trabalho no plano gratuito. No chat da app pergunta sempre primeiro. |
| openBillingPortal | A ligação para o portal de faturação, onde o plano se altera ou cancela e o cartão se atualiza. No chat da app pergunta sempre primeiro. |
| listInvoices | Cada cobrança com o estado da sua fatura, como o Histórico de Planos e faturação as lista, uma página de cada vez. |
| getInvoice | A ligação para a fatura de uma cobrança, um PDF, já que uma ferramenta não transporta ficheiros. |
| saveBillingDetails | Guardar o nome e a morada faturados numa cobrança, manter a morada para as cobranças seguintes e começar a emitir a sua fatura. No chat da app pergunta sempre primeiro. |
Só o proprietário do espaço de trabalho chega à faturação, através de um cliente ligado com todos os endereços. Ler requer billing:read e cada alteração requer billing:write.
Nada se paga através de uma ferramenta. Um pagamento, o portal de faturação e adicionar um cartão para o pagamento por utilização devolvem cada um uma ligação para a pessoa abrir, e é lá que ela paga, muda o cartão ou cancela.
Algumas ferramentas deste servidor fazem uma alteração que a API REST protege com um código de verificação, e pedem o mesmo código. Enquanto o cliente não tiver verificado um código nos últimos 60 minutos, e a pessoa não tiver escolhido Permitir alterações durante 60 minutos para ele em Conta → Aplicações ligadas, essa ferramenta responde com um resultado que começa por Refused (step_up_required): e não altera nada. emptyAudience nunca pede um código. A página Autenticação da API lista cada ferramenta que o pede e mostra como pedir um código e verificá-lo.
Referência
getBilling
The plan of this workspace and what it includes, as Plans & Billing shows it: how it is billed, when it renews or ends and the next charge, how many domains it holds, how much of this month's sends and today's AI actions are used, and pay as you go. Only the owner of the workspace reaches billing, through a client connected with every address.
Entradas
Não recebe entradas.
Também disponível em
listBillingPlans
Every plan, cheapest first, with its price, whether it is sold here and at which intervals, and what it includes. Prices are in US dollars. Only the owner of the workspace reaches billing, through a client connected with every address.
Entradas
Não recebe entradas.
Também disponível em
getBillingUsage
Sends and AI actions per day, and what pay as you go extras cost per month, as the Usage charts show them. days goes back 1 to 3660 days, 30 by default, and "all" goes back to the day the workspace was made. Days with no use are left out. Only the owner of the workspace reaches billing, through a client connected with every address.
Entradas
daysinteger | string
Também disponível em
listBillingAlerts
What the billing banner of the app would say now, most urgent first: a failed payment, paused pay as you go, sending or AI paused at a limit, a plan about to end, an allowance nearly used and a charge coming soon. Only the owner of the workspace reaches billing, through a client connected with every address.
Entradas
Não recebe entradas.
Também disponível em
listBillingCountries
Every country a billing address can be in, as the two-letter ISO 3166 codes saveBillingDetails takes as country. Only the owner of the workspace reaches billing, through a client connected with every address.
Entradas
Não recebe entradas.
Também disponível em
getPayAsYouGo
Pay as you go on this workspace: whether usage past the allowances is billed, the monthly limit and what extras cost so far, the current billing period, the limits that can be chosen and the prices. Only the owner of the workspace reaches billing, through a client connected with every address.
Entradas
Não recebe entradas.
Também disponível em
setPayAsYouGo
Turn pay as you go on or off, as the switch on Plans & Billing does. Off takes effect at once, and usage stops at the plan's allowances. On takes effect at once when a card is saved. The first time, it returns a link where the person adds a card on the billing provider's page: give them the link, and call confirmPayAsYouGo once they say they are done. Nothing is paid through this tool. It asks for a verification code, and in the app's chat it always asks first. Only the owner of the workspace reaches billing, through a client connected with every address.
- Pede um código de verificação
PATCH /billing/pay-as-you-go
Entradas
enabledbooleanObrigatóriothemestringLight or dark, for the page the link opens. Left out, it follows the browser.
Um de"light""dark"localestringA language tag such as de or pt-PT, for the page the link opens.
Até 35 caracteres
Também disponível em
setPayAsYouGoLimit
Set the monthly spending limit of pay as you go, in US cents. Extras stop for the rest of a calendar month once it is reached. Pay as you go has to be set up first. It asks for a verification code, and in the app's chat it always asks first. Only the owner of the workspace reaches billing, through a client connected with every address.
- Pede um código de verificação
PUT /billing/pay-as-you-go/limit
Entradas
limitCentsintegerObrigatórioOne of 1000, 2500, 5000, 10000, 25000, 50000, 100000, 250000, 500000.
Também disponível em
confirmPayAsYouGo
After the person added a card through the link setPayAsYouGo gave, check with the billing provider that it was saved and record it, as the app does when they come back. It asks for a verification code, and in the app's chat it always asks first. Only the owner of the workspace reaches billing, through a client connected with every address.
- Pede um código de verificação
POST /billing/pay-as-you-go/confirm
Entradas
Não recebe entradas.
Também disponível em
startPlanCheckout
Start buying a paid plan for a workspace on Free, as choosing a plan in the app does, and return the link to the checkout on the billing provider's page. Nothing is charged until the person pays there, so give them the link. A workspace that already pays for a plan changes it with openBillingPortal instead. interval is month or year, month by default. It asks for a verification code, and in the app's chat it always asks first. Only the owner of the workspace reaches billing, through a client connected with every address.
- Pede um código de verificação
POST /billing/checkout
Entradas
planstringObrigatório- Um de
"starter""business""enterprise" intervalstring- Um de
"month""year" themestringLight or dark, for the page the link opens. Left out, it follows the browser.
Um de"light""dark"localestringA language tag such as de or pt-PT, for the page the link opens.
Até 35 caracteres
Também disponível em
openBillingPortal
A link to the billing portal, where the person changes or cancels the plan, updates the card and downloads past invoices, as Manage does in the app. Nothing changes until they act there. It asks for a verification code, and in the app's chat it always asks first. Only the owner of the workspace reaches billing, through a client connected with every address.
- Pede um código de verificação
POST /billing/portal
Entradas
themestringLight or dark, for the page the link opens. Left out, it follows the browser.
Um de"light""dark"localestringA language tag such as de or pt-PT, for the page the link opens.
Até 35 caracteres
Também disponível em
listInvoices
Every charge of the workspace with the state of its invoice, as History on Plans & Billing lists them, newest first unless sort is oldest. search matches the plan, the invoice number, the charge id and the name billed. getInvoice returns the link to an invoice. Only the owner of the workspace reaches billing, through a client connected with every address.
Entradas
pageinteger- Pelo menos 1
limitinteger- Pelo menos 1No máximo 100
sortstring- Um de
"newest""oldest" searchstring- Até 120 caracteres
Também disponível em
getInvoice
The link to the invoice of one charge, a PDF, since a tool carries no file. An invoice that was not written yet is written first, which takes a few seconds. Take the charge id from listInvoices. Only the owner of the workspace reaches billing, through a client connected with every address.
Entradas
orderIdstringObrigatório- Não vazio
Também disponível em
saveBillingDetails
Save the name and address billed on a charge, as the Billing address dialog does, keep the address for later charges, and start writing its invoice. country is a two-letter code from listBillingCountries, and in the US and Canada state is its two-letter code. It asks for a verification code, and in the app's chat it always asks first. Only the owner of the workspace reaches billing, through a client connected with every address.
- Pede um código de verificação
PUT /billing/invoices/{orderId}/details
Entradas
orderIdstringObrigatório- Não vazio
namestringObrigatório- De 1 a 200 caracteres
line1stringObrigatório- De 1 a 200 caracteres
line2string- Até 200 caracteres
citystringObrigatório- De 1 a 120 caracteres
postalCodestring- Até 40 caracteres
statestring- Até 60 caracteres
countrystringObrigatório- Um de
"AD""AE""AF""AG""AI""AL""AM""AO""AQ""AR""AS""AT""AU""AW""AX""AZ""BA""BB""BD""BE""BF""BG""BH""BI""BJ""BL""BM""BN""BO""BQ""BR""BS""BT""BV""BW""BY""BZ""CA""CC""CD""CF""CG""CH""CI""CK""CL""CM""CN""CO""CR""CV""CW""CX""CY""CZ""DE""DJ""DK""DM""DO""DZ""EC""EE""EG""EH""ER""ES""ET""FI""FJ""FK""FM""FO""FR""GA""GB""GD""GE""GF""GG""GH""GI""GL""GM""GN""GP""GQ""GR""GS""GT""GU""GW""GY""HK""HM""HN""HR""HT""HU""ID""IE""IL""IM""IN""IO""IQ""IS""IT""JE""JM""JO""JP""KE""KG""KH""KI""KM""KN""KR""KW""KY""KZ""LA""LB""LC""LI""LK""LR""LS""LT""LU""LV""LY""MA""MC""MD""ME""MF""MG""MH""MK""ML""MM""MN""MO""MP""MQ""MR""MS""MT""MU""MV""MW""MX""MY""MZ""NA""NC""NE""NF""NG""NI""NL""NO""NP""NR""NU""NZ""OM""PA""PE""PF""PG""PH""PK""PL""PM""PN""PR""PS""PT""PW""PY""QA""RE""RO""RS""RW""SA""SB""SC""SD""SE""SG""SH""SI""SJ""SK""SL""SM""SN""SO""SR""SS""ST""SV""SX""SZ""TC""TD""TF""TG""TH""TJ""TK""TL""TM""TN""TO""TR""TT""TV""TW""TZ""UA""UG""UM""US""UY""UZ""VA""VC""VE""VG""VI""VN""VU""WF""WS""YE""YT""ZA""ZM""ZW"