soeru Cost Management (Admin) API
The Cost Management (Admin) API from soeru — 5 operation(s) for cost management (admin).
The Cost Management (Admin) API from soeru — 5 operation(s) for cost management (admin).
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/soeru-biz:soeru-biz-cost-management-admin-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: soeru Cost Management (Admin) API
description: AIパーソナライズ明細書メッセージ自動生成SaaS
version: 0.1.0
tags:
- name: Cost Management (Admin)
paths:
/api/messages/admin/cost-management/inventory:
get:
tags:
- Cost Management (Admin)
summary: List Inventory
description: '全 API 発火点 + 各 plan の現在 cap + 当月サマリを返す.
レスポンス構造:
{
summary: {当月コスト/revenue/margin},
grouped: {manual / per_message / auto / cron},
per_message_by_engine: {v3 / v2 / v1 / shared} ← engine 別の grouping
quota_groups: [{quota_key + 紐付き経路}],
}'
operationId: list_inventory_api_messages_admin_cost_management_inventory_get
parameters:
- name: authorization
in: header
required: true
schema:
type: string
description: Bearer <token>
title: Authorization
description: Bearer <token>
responses:
'200':
description: Successful Response
content:
application/json:
schema:
type: object
additionalProperties: true
title: Response List Inventory Api Messages Admin Cost Management Inventory Get
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/messages/admin/cost-management/quota-keys:
get:
tags:
- Cost Management (Admin)
summary: List Quota Keys
description: 'quota キー一覧 + 各 quota の現在 cap (Phase 2: DB override 込み).
PATCH /quota/{plan}/{operation} で各 cell を編集可能。'
operationId: list_quota_keys_api_messages_admin_cost_management_quota_keys_get
parameters:
- name: authorization
in: header
required: true
schema:
type: string
description: Bearer <token>
title: Authorization
description: Bearer <token>
responses:
'200':
description: Successful Response
content:
application/json:
schema:
type: object
additionalProperties: true
title: Response List Quota Keys Api Messages Admin Cost Management Quota Keys Get
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/messages/admin/cost-management/quota/{plan}/{operation}:
patch:
tags:
- Cost Management (Admin)
summary: Update Quota Override
description: 'plan × operation の月間 cap を DB override で上書き.
flow:
1. validate (plan / operation / monthly_cap range / 巨大値 confirm)
2. 旧値を取得 (audit log の old_cap 用)
3. quota_overrides を UPSERT
4. quota_override_log に audit 行を INSERT
5. invalidate_cap_cache() で自 process の cache をパージ
(他 instance は最大 60s 遅延で自然反映)'
operationId: update_quota_override_api_messages_admin_cost_management_quota__plan___operation__patch
parameters:
- name: plan
in: path
required: true
schema:
type: string
title: Plan
- name: operation
in: path
required: true
schema:
type: string
title: Operation
- name: authorization
in: header
required: true
schema:
type: string
description: Bearer <token>
title: Authorization
description: Bearer <token>
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/CapPatchRequest'
responses:
'200':
description: Successful Response
content:
application/json:
schema:
type: object
additionalProperties: true
title: Response Update Quota Override Api Messages Admin Cost Management Quota Plan Operation Patch
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/messages/admin/cost-management/quota/audit-log:
get:
tags:
- Cost Management (Admin)
summary: Get Audit Log
description: 'quota_override_log の最新 N 件を返す.
UI の「変更履歴」セクション用。set_by uuid → email を 1 round-trip で
引いて表示用に同梱。'
operationId: get_audit_log_api_messages_admin_cost_management_quota_audit_log_get
parameters:
- name: plan
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Plan
- name: operation
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Operation
- name: limit
in: query
required: false
schema:
type: integer
maximum: 500
minimum: 1
default: 50
title: Limit
- name: authorization
in: header
required: true
schema:
type: string
description: Bearer <token>
title: Authorization
description: Bearer <token>
responses:
'200':
description: Successful Response
content:
application/json:
schema:
type: object
additionalProperties: true
title: Response Get Audit Log Api Messages Admin Cost Management Quota Audit Log Get
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/api/messages/admin/cost-management/prelaunch-mode:
get:
tags:
- Cost Management (Admin)
summary: Get Prelaunch Mode
description: ローンチ前低コストモードの現在状態を返す (admin-only).
operationId: get_prelaunch_mode_api_messages_admin_cost_management_prelaunch_mode_get
parameters:
- name: authorization
in: header
required: true
schema:
type: string
description: Bearer <token>
title: Authorization
description: Bearer <token>
responses:
'200':
description: Successful Response
content:
application/json:
schema:
type: object
additionalProperties: true
title: Response Get Prelaunch Mode Api Messages Admin Cost Management Prelaunch Mode Get
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
post:
tags:
- Cost Management (Admin)
summary: Set Prelaunch Mode
description: 'ローンチ前低コストモードを ON/OFF する (admin-only, 再デプロイ不要).
ON: cache keepalive / 異常検知 digest / ブランドクローラ の定期発火を停止し、
日々の自動コストをほぼゼロにする. 注文同期など実害のある低コスト job は対象外.
OFF: 次の tick から各 job が再開する.'
operationId: set_prelaunch_mode_api_messages_admin_cost_management_prelaunch_mode_post
parameters:
- name: authorization
in: header
required: true
schema:
type: string
description: Bearer <token>
title: Authorization
description: Bearer <token>
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/PrelaunchModeRequest'
responses:
'200':
description: Successful Response
content:
application/json:
schema:
type: object
additionalProperties: true
title: Response Set Prelaunch Mode Api Messages Admin Cost Management Prelaunch Mode Post
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
components:
schemas:
PrelaunchModeRequest:
properties:
enabled:
type: boolean
title: Enabled
note:
anyOf:
- type: string
maxLength: 500
- type: 'null'
title: Note
type: object
required:
- enabled
title: PrelaunchModeRequest
description: POST /prelaunch-mode body.
ValidationError:
properties:
loc:
items:
anyOf:
- type: string
- type: integer
type: array
title: Location
msg:
type: string
title: Message
type:
type: string
title: Error Type
input:
title: Input
ctx:
type: object
title: Context
type: object
required:
- loc
- msg
- type
title: ValidationError
HTTPValidationError:
properties:
detail:
items:
$ref: '#/components/schemas/ValidationError'
type: array
title: Detail
type: object
title: HTTPValidationError
CapPatchRequest:
properties:
monthly_cap:
type: integer
maximum: 100000.0
minimum: 0.0
title: Monthly Cap
reason:
anyOf:
- type: string
maxLength: 500
- type: 'null'
title: Reason
confirm_large_value:
type: boolean
title: Confirm Large Value
default: false
type: object
required:
- monthly_cap
title: CapPatchRequest
description: PATCH /quota/{plan}/{operation} body.