Skip to main content
Glama

Cooper Email

Provision phone number

cooper_provision_phone_number
Destructive

Provision a US local number for an inbox. Requires auth. Free includes no numbers (HTTP 402). Starter caps at 3. Pro includes 3 and caps at 25. Each billable number is $3/month with 100 segments. With COOPER_SMS_BILLING=stripe the number is added to the Stripe subscription, prorated, before Cooper buys it. Otherwise billing.status is stub and this call does not charge. The number can receive SMS. Send returns 409 outbound_not_registered. Inputs: inbox_id (required), area_code or phone_number, idempotency_key (optional). Returns the phone number and billing.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "inbox_id": "<inbox_id>"
    },
    "name": "cooper_provision_phone_number"
  }
}

Input Schema

NameRequiredDescriptionDefault
inbox_idYesInbox id (inb_…) that owns the phone number. Get it from cooper_list_inboxes.
area_codeNoThree-digit US area code with numbers in stock, for example 650. Check GET /api/v1/phone-numbers/available?area_code= first: an empty list means no stock in that area code, and the search then suggests nearby or any US numbers. A sold-out area_code is refused with 409 area_code_sold_out and nearby_area_codes, and nothing is charged. Use this or phone_number.
phone_numberNoA specific available number in E.164 from GET /api/v1/phone-numbers/available, for example +16505550100. Use this or area_code.
idempotency_keyNoOptional key. Retrying with the same key returns the first result and does not buy a second number.

Output Schema

NameRequiredDescriptionDefault
idNoStable id of the returned object. Pass it to the matching get, update, or delete tool.
e164NoThe phone number in E.164.
objectNoObject type name, such as list, message, or thread.
statusNoactive or released.
billingNoBilling result for this number, such as {status}.
inbox_idNoInbox id (inb_…) this object belongs to. Null when it applies to every inbox.
outboundNoOutbound SMS registration state. Sends fail with outbound_not_registered until it is ready.
providerNoCarrier provider name.
account_idNoCooper account id (acct_…) that owns this object.
created_atNoISO-8601 time the object was created.
number_typeNoNumber type, such as local.
released_atNoISO-8601 time the number was released, or null.
capabilitiesNoWhat the number supports, such as sms and voice.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / area_code / description
      Previous value: -"Three-digit US area code with numbers in stock, for example 650. Check GET /api/v1/phone-numbers/available?area_code= first: an empty list means no stock in that area code, and the search then suggests nearby or any US numbers. Use this or phone_number."New value: +"Three-digit US area code with numbers in stock, for example 650. Check GET /api/v1/phone-numbers/available?area_code= first: an empty list means no stock in that area code, and the search then suggests nearby or any US numbers. A sold-out area_code is refused with 409 area_code_sold_out and nearby_area_codes, and nothing is charged. Use this or phone_number."
  2. Changed2 schema fields changed
    • changedInput schema / properties / area_code / description
      Previous value: -"Three-digit US area code to search, for example 415. Use this or phone_number."New value: +"Three-digit US area code with numbers in stock, for example 650. Check GET /api/v1/phone-numbers/available?area_code= first: an empty list means no stock in that area code, and the search then suggests nearby or any US numbers. Use this or phone_number."
    • changedInput schema / properties / phone_number / description
      Previous value: -"A specific available number in E.164, for example +14155550100. Use this or area_code."New value: +"A specific available number in E.164 from GET /api/v1/phone-numbers/available, for example +16505550100. Use this or area_code."
  3. Changed5 schema fields changed
    • addedInput schema / properties / area_code / description
      Added value: +"Three-digit US area code to search, for example 415. Use this or phone_number."
    • addedInput schema / properties / idempotency_key / description
      Added value: +"Optional key. Retrying with the same key returns the first result and does not buy a second number."
    • addedInput schema / properties / inbox_id / description
      Added value: +"Inbox id (inb_…) that owns the phone number. Get it from cooper_list_inboxes."
    • addedInput schema / properties / phone_number / description
      Added value: +"A specific available number in E.164, for example +14155550100. Use this or area_code."
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "additionalProperties": true,
      +  "description": "The new phone number and its billing.",
      +  "properties": {
      +    "account_id": {
      +      "description": "Cooper account id (acct_…) that owns this object."
      +    },
      +    "billing": {
      +      "description": "Billing result for this number, such as {status}."
      +    },
      +    "capabilities": {
      +      "description": "What the number supports, such as sms and voice."
      +    },
      +    "created_at": {
      +      "description": "ISO-8601 time the object was created."
      +    },
      +    "e164": {
      +      "description": "The phone number in E.164."
      +    },
      +    "id": {
      +      "description": "Stable id of the returned object. Pass it to the matching get, update, or delete tool."
      +    },
      +    "inbox_id": {
      +      "description": "Inbox id (inb_…) this object belongs to. Null when it applies to every inbox."
      +    },
      +    "number_type": {
      +      "description": "Number type, such as local."
      +    },
      +    "object": {
      +      "description": "Object type name, such as list, message, or thread."
      +    },
      +    "outbound": {
      +      "description": "Outbound SMS registration state. Sends fail with outbound_not_registered until it is ready."
      +    },
      +    "provider": {
      +      "description": "Carrier provider name."
      +    },
      +    "released_at": {
      +      "description": "ISO-8601 time the number was released, or null."
      +    },
      +    "status": {
      +      "description": "active or released."
      +    }
      +  },
      +  "type": "object"
      +}
  4. Added

TDQS

A4/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Substantially exceeds the annotations (readOnly=false, destructive=true, openWorld=true): it discloses recurring $3/month cost with 100 segments, proration before purchase under stripe billing, that billing.status stays stub and no charge occurs otherwise, the 402 plan gate, and the 409 outbound_not_registered send behavior. It also nuances the idempotentHint=false annotation by explaining that supplying idempotency_key prevents a duplicate purchase.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Dense but front-loaded: purpose first, then plan caps, billing behavior, and side effects. The final 'Inputs:' enumeration and 'Returns the phone number and billing' sentence duplicate the 100%-covered schema and the existing output schema, which is the only real waste.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers auth, plan limits, cost model, and the main failure modes, which is most of what a destructive purchase call needs. Gaps remain around lifecycle after provisioning — how the number is later released and whether charges stop — and the output description is redundant rather than informative given a declared output schema.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the schema already documents inbox_id, area_code, phone_number and idempotency_key, including the availability endpoint and 409 error codes. The trailing 'Inputs:' recap restates the schema rather than adding new meaning, so the baseline of 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb and resource: 'Provision a US local number for an inbox', plus scope details (US local, tied to an inbox). It is immediately distinguishable from read-shaped siblings like cooper_get_phone_number, though it never names which sibling to use for the inverse operation (release).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives strong when-to-use context: plan entitlements (Free = none/402, Starter = 3, Pro = 3 with cap 25), the availability pre-check, and the 409 area_code_sold_out path. It stops short of explicit routing to alternatives such as cooper_release_phone_number for removal or cooper_billing_status for cost inspection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.