Hive Civilization Arb Alloc API

The arb-alloc API from Hive Civilization — 4 operation(s) for arb-alloc.

Operations 4

GET /v1/arb/alloc/scan Alloc Scan #
POST /v1/arb/alloc/apply Alloc Apply #
GET /v1/arb/alloc/history Alloc History #
GET /v1/arb/alloc/stats Alloc Stats #

Documentation

Specifications

Other Resources

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • 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.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/thehiveryiq-com-arb-alloc-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API 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. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

thehiveryiq-com-arb-alloc-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: HiveMorph v0.1 Arb Alloc API
  description: 'Polymorphic agent runtime — single shape (Merchant), single supermodel (W2 MERCHANT). Three gates: NEED + YIELD + CLEAN-MONEY.'
  version: 0.1.0
tags:
- name: arb-alloc
paths:
  /v1/arb/alloc/scan:
    get:
      tags:
      - arb-alloc
      summary: Alloc Scan
      description: 'Read-only performance snapshot + recommended slot-share deltas.


        Returns a list of AllocProposal objects, one per supermodel brood that has

        live variants. Each proposal includes:

        - Per-variant scores (revenue_per_offer × confidence × recency)

        - Softmax-with-floor target shares (every variant keeps ≥ 5%)

        - Delta vs current equal-split share

        - Winner (highest target_share) and loser (lowest) identification

        - Integration gap: what runtime.py change is needed to realise the weights'
      operationId: alloc_scan_v1_arb_alloc_scan_get
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
  /v1/arb/alloc/apply:
    post:
      tags:
      - arb-alloc
      summary: Alloc Apply
      description: 'Apply reallocation.


        dry_run=true (default): compute and return proposals only.

        dry_run=false: persist proposals to alloc_history.


        IMPORTANT: Until runtime.py is patched with the per_variant_weights hook

        (see integration_gap in each proposal), applying dry_run=false logs the

        intent but does NOT change live traffic routing weights. This is a soft

        apply — the allocator records the desired state so Steve can wire it up.'
      operationId: alloc_apply_v1_arb_alloc_apply_post
      parameters:
      - name: dry_run
        in: query
        required: false
        schema:
          type: boolean
          description: If true (default), compute only. If false, log to alloc_history.
          default: true
          title: Dry Run
        description: If true (default), compute only. If false, log to alloc_history.
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /v1/arb/alloc/history:
    get:
      tags:
      - arb-alloc
      summary: Alloc History
      description: 'Past reallocation events (dry_run=False runs only).


        Each record contains:

        - applied_at timestamp

        - parent_id of the brood affected

        - Full proposal snapshot (variants, scores, deltas) at apply time

        - note field with integration status'
      operationId: alloc_history_v1_arb_alloc_history_get
      parameters:
      - name: parent_id
        in: query
        required: false
        schema:
          anyOf:
          - type: string
          - type: 'null'
          description: Filter to a specific supermodel parent_id
          title: Parent Id
        description: Filter to a specific supermodel parent_id
      - name: limit
        in: query
        required: false
        schema:
          type: integer
          maximum: 500
          minimum: 1
          description: Max records to return
          default: 50
          title: Limit
        description: Max records to return
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /v1/arb/alloc/stats:
    get:
      tags:
      - arb-alloc
      summary: Alloc Stats
      description: 'Projected uplift attributable to slot reallocations.


        Computes the mean revenue_per_offer of winners vs losers across all

        alloc_history events in the lookback window. Uplift is labelled

        "projected" because actual traffic reweighting is pending the runtime.py

        integration point (per_variant_weights kwarg in select_routing_target).


        Returns:

        - lookback_hours

        - total_reallocation_events

        - unique_parents_affected

        - avg_winner_rpo / avg_loser_rpo

        - projected_uplift_pct

        - note (integration status)'
      operationId: alloc_stats_v1_arb_alloc_stats_get
      parameters:
      - name: lookback_hours
        in: query
        required: false
        schema:
          type: number
          maximum: 8760.0
          minimum: 1.0
          description: Hours to look back for uplift computation
          default: 24.0
          title: Lookback Hours
        description: Hours to look back for uplift computation
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    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