{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-docs/api-reference/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":["api-container","api-content","endpoint","api-examples","code-group","tabs","tab"]},"redocly_category":"API Reference","searchWeight":120,"type":"markdown"},"seo":{"title":"Choose the default billing organization","description":"Complete API reference and documentation for Freddy AI-powered backend system by Aitronos","llmstxt":{"hide":false,"sections":[{"title":"Table of contents","includeFiles":["**/*"],"excludeFiles":[]}],"excludeFiles":[]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"choose-the-default-billing-organization","__idx":0},"children":["Choose the default billing organization"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Saves which organization to preselect as ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Bill to"]}," when you rent a Forge cloud server, and returns the ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/list-billing-organizations"},"children":["billing organizations"]}," with it as ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["default_organization_id"]},". The choice is yours alone and follows you across devices."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["It only preselects. Every server is billed to the organization its ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/create-host"},"children":["create"]}," names in ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["organization_id"]},", and nothing already running moves. If the saved organization later stops being selectable, the list falls back to your current organization, or the first selectable one, until you choose again."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The organization must be one of yours marked ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["selectable"]}," in ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/list-billing-organizations"},"children":["List billing organizations"]},". Otherwise the request is refused with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["403 FORGE_COMPUTE_BILLING_ORGANIZATION_NOT_SELECTABLE"]},", whose ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["message"]}," is the reason to show, and nothing is saved. Requires a credential that acts for a person; one confined to some organizations can choose only among those."]},{"$$mdtype":"Tag","name":"ApiContainer","attributes":{},"children":[{"$$mdtype":"Tag","name":"ApiContent","attributes":{},"children":[{"$$mdtype":"Tag","name":"Endpoint","attributes":{"method":"PUT","path":"https://api.aitronos.com/v1/forge/compute/billing-organizations/default"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"body-parameters","__idx":1},"children":["Body Parameters"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["organization_id"]}]}," string ",{"$$mdtype":"Tag","name":"em","attributes":{"style":{"color":"#ef4444 !important","fontWeight":"600 !important","fontStyle":"normal !important"}},"children":["required"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The organization to preselect: an ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["id"]}," from ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["organizations"]}," marked ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["selectable"]},". Unknown fields are refused."]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"returns","__idx":2},"children":["Returns"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/list-billing-organizations#returns"},"children":["billing organizations"]},", with ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["default_organization_id"]}," set to the chosen organization."]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"json","header":{"controls":{"copy":{}}},"source":"{\n  \"default_organization_id\": \"org_8f2d4b6a1c3e4f5a8b7c9d0e1f2a3b4c\",\n  \"title\": \"Bill to\",\n  \"help\": \"Rented servers are billed to this organization's Forge cloud compute.\",\n  \"organizations\": [\n    {\n      \"id\": \"org_3c1e9a7b5d2f4e8a9b0c6d1e2f3a4b5c\",\n      \"name\": \"Acme Engineering\",\n      \"logo_url\": \"https://cdn.example.com/logos/acme.png\",\n      \"selectable\": true,\n      \"reason\": null,\n      \"month_to_date_label\": \"CHF 0.52 on servers this month\",\n      \"order\": 0\n    },\n    {\n      \"id\": \"org_8f2d4b6a1c3e4f5a8b7c9d0e1f2a3b4c\",\n      \"name\": \"Side Project\",\n      \"logo_url\": null,\n      \"selectable\": true,\n      \"reason\": null,\n      \"month_to_date_label\": null,\n      \"order\": 1\n    }\n  ]\n}\n","lang":"json"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"errors","__idx":3},"children":["Errors"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Status"},"children":["Status"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Code"},"children":["Code"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"When"},"children":["When"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["401"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["AUTHENTICATION_REQUIRED"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["No valid credential."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["403"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["API_KEY_PERSON_REQUIRED"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["An organization API key: it has no person of its own."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["403"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["FORGE_COMPUTE_BILLING_ORGANIZATION_NOT_SELECTABLE"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Servers cannot be billed to this organization: you are not an active member of it, your credential is confined to other organizations (\"This key cannot be used in this organization.\"), Forge cloud compute is off there or could not be checked, you do not hold ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["use_forge"]}," there, or Aitronos servers are not offered to you there. ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["message"]}," is the reason to show; ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["details.organization_id"]}," is the organization. Nothing was saved."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":["422"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["VALIDATION_ERROR"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["A body of the wrong shape: ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["organization_id"]}," missing or empty, or an unknown field."]}]}]}]}]}]},{"$$mdtype":"Tag","name":"ApiExamples","attributes":{},"children":[{"$$mdtype":"Tag","name":"CodeGroup","attributes":{"mode":"dropdown"},"children":[{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","data-title":"cURL","header":{"title":"cURL","controls":{"copy":{}}},"source":"curl -X PUT \"https://api.aitronos.com/v1/forge/compute/billing-organizations/default\" \\\n  -H \"Authorization: Bearer $ACCESS_TOKEN\" \\\n  -H \"Content-Type: application/json\" \\\n  -d '{\"organization_id\": \"org_8f2d4b6a1c3e4f5a8b7c9d0e1f2a3b4c\"}'\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"python","data-title":"Python SDK","header":{"title":"Python SDK","controls":{"copy":{}}},"source":"# pip install aitronos-sdk\n#\n# The Python SDK does not expose a typed `forge_compute` namespace yet, so call\n# the endpoint directly with the same bearer token you would pass to `Aitronos(...)`.\nimport httpx\n\nACCESS_TOKEN = \"your-access-token\"\n\nresponse = httpx.put(\n    \"https://api.aitronos.com/v1/forge/compute/billing-organizations/default\",\n    headers={\"Authorization\": f\"Bearer {ACCESS_TOKEN}\"},\n    json={\"organization_id\": \"org_8f2d4b6a1c3e4f5a8b7c9d0e1f2a3b4c\"},\n)\nif response.status_code == 403:\n    print(response.json()[\"error\"][\"message\"])\nelse:\n    print(\"default:\", response.json()[\"default_organization_id\"])\n","lang":"python"},"children":[]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"python","data-title":"Python","header":{"title":"Python","controls":{"copy":{}}},"source":"import os\nimport requests\n\ntoken = os.environ[\"AITRONOS_TOKEN\"]\nresponse = requests.put(\n    \"https://api.aitronos.com/v1/forge/compute/billing-organizations/default\",\n    headers={\"Authorization\": f\"Bearer {token}\"},\n    json={\"organization_id\": \"org_8f2d4b6a1c3e4f5a8b7c9d0e1f2a3b4c\"},\n)\nprint(response.json()[\"default_organization_id\"])\n","lang":"python"},"children":[]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"javascript","data-title":"JavaScript","header":{"title":"JavaScript","controls":{"copy":{}}},"source":"const response = await fetch(\"https://api.aitronos.com/v1/forge/compute/billing-organizations/default\", {\n  method: \"PUT\",\n  headers: {\n    Authorization: `Bearer ${process.env.AITRONOS_TOKEN}`,\n    \"Content-Type\": \"application/json\",\n  },\n  body: JSON.stringify({ organization_id: \"org_8f2d4b6a1c3e4f5a8b7c9d0e1f2a3b4c\" }),\n});\nconst picker = await response.json();\nconsole.log(picker.default_organization_id);\n","lang":"javascript"},"children":[]}]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Response:"]}]},{"$$mdtype":"Tag","name":"Tabs","attributes":{"size":"medium"},"children":[{"$$mdtype":"Tag","name":"div","attributes":{"label":"200 OK","disable":false},"children":[{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"json","header":{"controls":{"copy":{}}},"source":"{\n  \"default_organization_id\": \"org_8f2d4b6a1c3e4f5a8b7c9d0e1f2a3b4c\",\n  \"title\": \"Bill to\",\n  \"help\": \"Rented servers are billed to this organization's Forge cloud compute.\",\n  \"organizations\": [\n    {\n      \"id\": \"org_3c1e9a7b5d2f4e8a9b0c6d1e2f3a4b5c\",\n      \"name\": \"Acme Engineering\",\n      \"logo_url\": \"https://cdn.example.com/logos/acme.png\",\n      \"selectable\": true,\n      \"reason\": null,\n      \"month_to_date_label\": \"CHF 0.52 on servers this month\",\n      \"order\": 0\n    },\n    {\n      \"id\": \"org_8f2d4b6a1c3e4f5a8b7c9d0e1f2a3b4c\",\n      \"name\": \"Side Project\",\n      \"logo_url\": null,\n      \"selectable\": true,\n      \"reason\": null,\n      \"month_to_date_label\": null,\n      \"order\": 1\n    }\n  ]\n}\n","lang":"json"},"children":[]}]},{"$$mdtype":"Tag","name":"div","attributes":{"label":"403 Forbidden","disable":false},"children":[{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"json","header":{"controls":{"copy":{}}},"source":"{\n  \"success\": false,\n  \"error\": {\n    \"code\": \"FORGE_COMPUTE_BILLING_ORGANIZATION_NOT_SELECTABLE\",\n    \"message\": \"You don't have permission to rent servers in this organization.\",\n    \"system_message\": \"Forge compute billing organization not selectable: 'org_1a2b3c4d5e6f4a7b8c9d0e1f2a3b4c5d'\",\n    \"type\": \"authorization_error\",\n    \"status\": 403,\n    \"details\": {\"organization_id\": \"org_1a2b3c4d5e6f4a7b8c9d0e1f2a3b4c5d\"},\n    \"trace_id\": \"3f1c9a52-7d4e-4b8a-9c21-6e0d5f7a8b34\",\n    \"timestamp\": \"2026-10-01T09:00:00Z\"\n  }\n}\n","lang":"json"},"children":[]}]}]}]}]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"related-resources","__idx":4},"children":["Related Resources"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/introduction"},"children":["Forge cloud compute overview"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/list-billing-organizations"},"children":["List billing organizations"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/choose-billing-organization"},"children":["Choose the default billing organization"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/list-project-groups"},"children":["List project groups"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/put-project-group"},"children":["Register or update a project group"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/delete-project-group"},"children":["Delete a project group"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/list-offerings"},"children":["List compute offerings"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/get-offering-options"},"children":["Get offering options"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/resolve-offering-size"},"children":["Resolve a free size"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/list-credentials"},"children":["List connected accounts"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/put-credential"},"children":["Connect a cloud account"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/delete-credential"},"children":["Disconnect a cloud account"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/create-host"},"children":["Create a server"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/list-hosts"},"children":["List servers"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/list-my-hosts"},"children":["List your servers in every organization"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/get-host"},"children":["Get a server"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/get-host-usage"},"children":["Get a server's daily cost and uptime"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/list-host-intervals"},"children":["List a server's running intervals"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/list-host-events"},"children":["List a server's event history"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/park-host"},"children":["Park a server"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/resume-host"},"children":["Resume a server"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/delete-host"},"children":["Delete a server"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/get-settings"},"children":["Get compute settings"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/get-limits"},"children":["Get spend limits"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/update-organization-limits"},"children":["Change the organization's limits"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/update-my-limit"},"children":["Set your own limit"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/list-member-limits"},"children":["List member limits"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/docs/api-reference/forge-compute/update-member-limit"},"children":["Set a member's limit"]}]}]}]},"headings":[{"value":"Choose the default billing organization","id":"choose-the-default-billing-organization","depth":1},{"value":"Body Parameters","id":"body-parameters","depth":4},{"value":"Returns","id":"returns","depth":2},{"value":"Errors","id":"errors","depth":2},{"value":"Related Resources","id":"related-resources","depth":2}],"frontmatter":{"title":"Choose the default billing organization","keywords":["forge","cloud compute","servers","billing","organization","bill to","default"],"seo":{"title":"Choose the default billing organization"}},"lastModified":"2026-10-26T18:32:31.575Z","pagePropGetterError":{"message":"","name":""}},"slug":"/docs/api-reference/forge-compute/choose-billing-organization","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}