YouGame Agent API

The Agent API from YouGame, for agent.

GitHub OpenAPI
Pull this API's OpenAPI, operations, scores and pricing into your own code or AI agent with a free APIs.io key — sign in with GitHub, Google or LinkedIn. No form to fill in; signing in shares your email address with us (Privacy).

Operations 5

POST /api/agent/upload A small build's ZIP in one request. #
PUT /api/agent/media Adds a thumbnail, screenshot, or video to a staged upload. #
POST /api/agent/draft Fills in the whole listing of a staged build as a draft and returns a review… #
POST /api/agent/publish Publishes a staged build at once, for the creator. #
GET /api/agent/games The games the key's creator has published. Needs the creator's API key #

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/yougame-co:yougame-co-agent-api"
All apis
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.

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. 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 Specification

yougame-co-agent-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: YouGame Agent API
  version: 1.1.0
  description: 'YouGame hosts browser games: a creator, or their coding agent on their behalf, uploads a static build and it is live at https://yougame.co. Read the publish guide before making a game YouGame-ready, read the SDK reference for leaderboards, phone support, and multiplayer, and run checkBuild on the finished folder until the verdict is "ready". With the creator''s API key the agent does the rest on their behalf: it stages the build (startUpload, uploadFile, completeUpload), fills in the whole listing and publishes it (publishGame, creator_approved true: a creator who asked the agent to publish has approved it), and later ships new versions (POST /api/agent/update, in the publish guide). For a creator who wants to look first, prepareSubmission saves the listing and returns a review link where they press Publish. Only without a key, as a fallback, the creator uploads the zip at https://yougame.co/upload.'
servers:
- url: https://yougame.co
tags:
- name: Agent
paths:
  /api/agent/upload:
    post:
      operationId: uploadBuild
      summary: A small build's ZIP in one request.
      description: For a client that cannot send files one by one. The upload's limits are 5 GB per build and 512 MB per file through startUpload, uploadFile, completeUpload; a zip too big for one request is answered 413 with next.run, the upload-build.mjs line that sends the same zip. Send the zip of the build folder's contents as the raw body. The reply has the uploadId, a testUrl where the build already runs, the verdict, and the report; a broken verdict means fix and upload again.
      x-openai-isConsequential: false
      security:
      - apiKey: []
      requestBody:
        required: true
        content:
          application/zip:
            schema:
              type: string
              format: binary
      responses:
        '200':
          description: The staged upload.
          content:
            application/json:
              schema:
                type: object
                properties:
                  uploadId:
                    type: string
                  testUrl:
                    type: string
                  verdict:
                    type: string
                    enum:
                    - ready
                    - risky
                    - broken
                  report:
                    type: string
                  features:
                    type: array
                    items:
                      type: string
                  next:
                    type: string
        '400':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
        '401':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
        '413':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
      tags:
      - Agent
  /api/agent/media:
    put:
      operationId: addMedia
      summary: Adds a thumbnail, screenshot, or video to a staged upload.
      description: Send the file as the raw body with its Content-Type (image/png, image/jpeg, image/webp, image/gif; video/mp4, video/webm). thumb and video replace the current one; shot adds one (up to 8).
      x-openai-isConsequential: false
      security:
      - apiKey: []
      parameters:
      - name: uploadId
        in: query
        required: true
        schema:
          type: string
      - name: kind
        in: query
        required: true
        schema:
          type: string
          enum:
          - thumb
          - shot
          - video
      requestBody:
        required: true
        content:
          image/png:
            schema:
              type: string
              format: binary
          image/jpeg:
            schema:
              type: string
              format: binary
          image/webp:
            schema:
              type: string
              format: binary
          video/mp4:
            schema:
              type: string
              format: binary
      responses:
        '200':
          description: The media now on the upload.
          content:
            application/json:
              schema:
                type: object
                properties:
                  url:
                    type: string
                  media:
                    type: object
        '400':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
        '401':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
        '413':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
      tags:
      - Agent
  /api/agent/draft:
    post:
      operationId: prepareSubmission
      summary: Fills in the whole listing of a staged build as a draft and returns a review…
      description: 'Pass every field, decided from what you know about the game; ask the creator about anything the game cannot settle (a thumbnail, mature content) and about whatever the reply lists under questions, then call again with the answers. Give the creator the reviewUrl: they check the listing, change what they want, and press Publish there. Nothing is live until they do, or until they tell you to publish and you call publishGame with the uploadId.'
      x-openai-isConsequential: false
      security:
      - apiKey: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
              - uploadId
              - title
              properties:
                platform:
                  type: string
                  enum:
                  - web
                  - desktop_app
                  description: 'web (default): plays in the browser. desktop_app: native build only, uploaded after publishing (native_upload_token in the MCP, publish guide "Desktop builds"). Forces mobile false. Never ship a web page telling players to download the app.'
                uploadId:
                  type: string
                  description: From the upload reply (32 hex characters).
                title:
                  type: string
                  description: 1–80 characters.
                description:
                  type: string
                  description: 'Up to 1000 characters: what the game is and how to play, written from the game.'
                genres:
                  type: array
                  items:
                    type: string
                    enum:
                    - Action
                    - Adventure
                    - RPG
                    - Arcade
                    - Puzzle
                    - Platformer
                    - Shooter
                    - Fighting
                    - Strategy
                    - Simulation
                    - Sports
                    - Racing
                    - Party
                    - Horror
                    - Roguelike
                    - Card
                    - Idle
                    - Rhythm
                    - Tower defense
                    - Word
                    - Other
                  description: Up to 3; the first is the main one.
                controls:
                  type: string
                  enum:
                  - Keyboard
                  - Mouse
                  - Keyboard + Mouse
                  - Touch
                  - Gamepad
                play_mode:
                  type: string
                  enum:
                  - single
                  - multiplayer
                  - both
                  description: single, multiplayer, or both.
                mobile:
                  type: boolean
                  description: True only when the game plays with touch.
                mature:
                  type: boolean
                  description: True when the game is for adults only.
                score_kind:
                  type: string
                  enum:
                  - points
                  - time
                  - percent
                  description: 'What the board ranks by: points (default, higher wins), time (gameOver posts a run in milliseconds, fastest first, shown as 1:23.45), or percent (gameOver posts hundredths of a percent, 0 to 10000, highest first, shown as 66.1%).'
                leaderboard:
                  type: boolean
                  description: The everyone leaderboard (default true). false with friends_board true is a friends-only board.
                friends_board:
                  type: boolean
                  description: 'The friends leaderboard: the same scores, each signed-in player seeing only themself and their friends (default true).'
                ladder:
                  type: boolean
                  description: The ranked ladder that ranked online matches feed, on the game page (default true).
                match_replays:
                  type: boolean
                  description: Creator opt-in for automatic browser match recordings, live watching and player account copies. Default false. Requires YouGame.replay.matches in the game.
                voice_everyone:
                  type: boolean
                  description: 'Voice chat with everyone seated in a match, not just friends (default false: friends only). Match rooms only (first ten players), not worlds.'
                button_default:
                  type: string
                  enum:
                  - fade
                  - visible
                  - hidden
                  description: 'How the YouGame button over the game starts: "fade" (default, shows then fades; Esc, a message or the pointer at its corner brings it back), "visible" (always shown) or "hidden" (fully hidden; Shift+Tab or Back+Start opens YouGame). A player''s own choice wins.'
                whole_game_lobby:
                  type:
                  - boolean
                  - 'null'
                  description: true when online play is a single lobby that starts the whole game together; false when players pick among several lobby or mode types inside the game (no Play together button on its page). Omit if unsure; null clears the setting.
                max_score:
                  type: number
                  description: The highest score the game can produce (points), or the fastest run it can possibly produce in milliseconds (time); scores past it are refused.
                thumbnail:
                  type: string
                  description: Path inside the build of a 16:9 image for the card (not needed after PUT /api/agent/media).
                screenshots:
                  type: array
                  items:
                    type: string
                  description: Up to 8 image paths inside the build.
                notes:
                  type: string
                  description: What you decided and assumed, shown to the creator above the form.
      responses:
        '200':
          description: The saved draft.
          content:
            application/json:
              schema:
                type: object
                properties:
                  reviewUrl:
                    type: string
                  testUrl:
                    type: string
                  draft:
                    type: object
                  media:
                    type: object
                  questions:
                    type: array
                    items:
                      type: string
                  warnings:
                    type: array
                    items:
                      type: string
                  next:
                    type: string
        '400':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
        '401':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
        '404':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
        '409':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
      tags:
      - Agent
  /api/agent/publish:
    post:
      operationId: publishGame
      summary: Publishes a staged build at once, for the creator.
      description: 'How the agent publishes for the creator: when they asked you to publish the game, that request is their approval, so pass creator_approved true with the uploadId and every listing field. Not for a request only to make the game ready or check it. After prepareSubmission the uploadId alone is enough; every other field keeps the draft''s value.'
      x-openai-isConsequential: true
      security:
      - apiKey: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
              - uploadId
              - creator_approved
              properties:
                creator_approved:
                  type: boolean
                  description: 'True when the creator asked the agent to publish this game: their request to publish is the approval. The route refuses without it.'
                platform:
                  type: string
                  enum:
                  - web
                  - desktop_app
                  description: 'web (default): plays in the browser. desktop_app: native build only, uploaded after publishing (native_upload_token in the MCP, publish guide "Desktop builds"). Forces mobile false. Never ship a web page telling players to download the app.'
                uploadId:
                  type: string
                  description: From the upload reply (32 hex characters).
                title:
                  type: string
                  description: 1–80 characters.
                description:
                  type: string
                  description: 'Up to 1000 characters: what the game is and how to play, written from the game.'
                genres:
                  type: array
                  items:
                    type: string
                    enum:
                    - Action
                    - Adventure
                    - RPG
                    - Arcade
                    - Puzzle
                    - Platformer
                    - Shooter
                    - Fighting
                    - Strategy
                    - Simulation
                    - Sports
                    - Racing
                    - Party
                    - Horror
                    - Roguelike
                    - Card
                    - Idle
                    - Rhythm
                    - Tower defense
                    - Word
                    - Other
                  description: Up to 3; the first is the main one.
                controls:
                  type: string
                  enum:
                  - Keyboard
                  - Mouse
                  - Keyboard + Mouse
                  - Touch
                  - Gamepad
                play_mode:
                  type: string
                  enum:
                  - single
                  - multiplayer
                  - both
                  description: single, multiplayer, or both.
                mobile:
                  type: boolean
                  description: True only when the game plays with touch.
                mature:
                  type: boolean
                  description: True when the game is for adults only.
                score_kind:
                  type: string
                  enum:
                  - points
                  - time
                  - percent
                  description: 'What the board ranks by: points (default, higher wins), time (gameOver posts a run in milliseconds, fastest first, shown as 1:23.45), or percent (gameOver posts hundredths of a percent, 0 to 10000, highest first, shown as 66.1%).'
                leaderboard:
                  type: boolean
                  description: The everyone leaderboard (default true). false with friends_board true is a friends-only board.
                friends_board:
                  type: boolean
                  description: 'The friends leaderboard: the same scores, each signed-in player seeing only themself and their friends (default true).'
                ladder:
                  type: boolean
                  description: The ranked ladder that ranked online matches feed, on the game page (default true).
                match_replays:
                  type: boolean
                  description: Creator opt-in for automatic browser match recordings, live watching and player account copies. Default false. Requires YouGame.replay.matches in the game.
                voice_everyone:
                  type: boolean
                  description: 'Voice chat with everyone seated in a match, not just friends (default false: friends only). Match rooms only (first ten players), not worlds.'
                button_default:
                  type: string
                  enum:
                  - fade
                  - visible
                  - hidden
                  description: 'How the YouGame button over the game starts: "fade" (default, shows then fades; Esc, a message or the pointer at its corner brings it back), "visible" (always shown) or "hidden" (fully hidden; Shift+Tab or Back+Start opens YouGame). A player''s own choice wins.'
                whole_game_lobby:
                  type:
                  - boolean
                  - 'null'
                  description: true when online play is a single lobby that starts the whole game together; false when players pick among several lobby or mode types inside the game (no Play together button on its page). Omit if unsure; null clears the setting.
                max_score:
                  type: number
                  description: The highest score the game can produce (points), or the fastest run it can possibly produce in milliseconds (time); scores past it are refused.
                thumbnail:
                  type: string
                  description: Path inside the build of a 16:9 image for the card (not needed after PUT /api/agent/media).
                screenshots:
                  type: array
                  items:
                    type: string
                  description: Up to 8 image paths inside the build.
                save:
                  type: boolean
                  description: Put the game in the creator's Saved games. Default true; false only when the creator asked not to.
      responses:
        '200':
          description: The published game.
          content:
            application/json:
              schema:
                type: object
                properties:
                  slug:
                    type: string
                  url:
                    type: string
                  features:
                    type: array
                    items:
                      type: string
                  warnings:
                    type: array
                    items:
                      type: string
        '400':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
        '401':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
        '403':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
      tags:
      - Agent
  /api/agent/games:
    get:
      operationId: myGames
      summary: The games the key's creator has published. Needs the creator's API key
      x-openai-isConsequential: false
      security:
      - apiKey: []
      responses:
        '200':
          description: The games, newest first.
          content:
            application/json:
              schema:
                type: object
                properties:
                  games:
                    type: array
                    items:
                      type: object
        '401':
          description: What went wrong.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
      tags:
      - Agent
components:
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      description: The creator's API key (yg_…), made at /account under Coding agents.