> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mirurobotics.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create

> Create a new device.

| Scope           | Required |
| --------------- | -------- |
| `devices:write` | Yes      |


## OpenAPI

````yaml /references/platform-api/2026-03-09.yaml post /devices
openapi: 3.0.3
info:
  title: Miru Platform API
  description: The API between Miru and any external client
  version: 2026-03-09.tetons
  license:
    name: MIT
    url: https://opensource.org/licenses/MIT
  x-release-version: 2026-03-09.tetons
  x-git-commit:
    sha: a33cf62e35e950971e3c223d746ae8e4e6464442
    url: >-
      https://github.com/mirurobotics/openapi/commit/a33cf62e35e950971e3c223d746ae8e4e6464442
    message: |-
      refactor(stainless): rename config instance content method to download

      Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
    author: Benjamin Smidt
    branch: HEAD
    dirty: false
  x-build:
    built_at: '2026-03-08T22:30:32.695898+00:00'
servers:
  - url: https://api.mirurobotics.com/beta
    description: Miru Platform API
security:
  - ApiKeyAuth: []
paths:
  /devices:
    parameters:
      - $ref: '#/components/parameters/MiruVersion'
    post:
      tags:
        - Devices
      summary: Create
      description: Create a new device.
      operationId: createDevice
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateDeviceRequest'
      responses:
        '200':
          description: Successfully created the device.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Device'
      x-codeSamples:
        - lang: Python
          source: |-
            import os
            from miru_platform_sdk import Miru

            client = Miru(
                api_key=os.environ.get("MIRU_API_KEY"),  # This is the default and can be omitted
            )
            device = client.devices.create(
                name="Robot 1",
            )
            print(device.id)
components:
  parameters:
    MiruVersion:
      name: Miru-Version
      in: header
      required: true
      schema:
        type: string
        example: 2026-03-09.tetons
      description: The API version the client was built against.
  schemas:
    CreateDeviceRequest:
      title: Create Device Request
      type: object
      required:
        - name
      properties:
        name:
          type: string
          description: The name of the device.
          example: Robot 1
    Device:
      allOf:
        - $ref: '#/components/schemas/BaseDevice'
      example:
        object: device
        id: dvc_123
        name: My Device
        status: online
        agent_version: v1.0.0
        last_connected_at: '2021-01-01T00:00:00Z'
        last_disconnected_at: null
        created_at: '2021-01-01T00:00:00Z'
        updated_at: '2021-01-01T00:00:00Z'
    BaseDevice:
      title: Base Device
      type: object
      required:
        - object
        - id
        - name
        - status
        - agent_version
        - last_connected_at
        - last_disconnected_at
        - created_at
        - updated_at
      properties:
        object:
          type: string
          enum:
            - device
          example: device
          x-stainless-const: true
          description: The object type, which is always `device`.
        id:
          type: string
          example: dvc_123
          description: ID of the device.
        name:
          type: string
          example: My Device
          description: Name of the device.
        status:
          $ref: '#/components/schemas/DeviceStatus'
        agent_version:
          type: string
          example: v1.0.0
          description: The version of the agent the device is running.
          nullable: true
        last_connected_at:
          type: string
          format: date-time
          example: '2021-01-01T00:00:00Z'
          nullable: true
          description: >-
            Timestamp of when the device was last made an initial connection
            (this is not the same as the last time the device was seen).
        last_disconnected_at:
          type: string
          format: date-time
          example: '2021-01-01T00:00:00Z'
          nullable: true
          description: >-
            Timestamp of when the device was last disconnected (this is not the
            same as the last time the device was seen).
        created_at:
          type: string
          format: date-time
          example: '2021-01-01T00:00:00Z'
          description: Timestamp of when the device was created.
        updated_at:
          type: string
          format: date-time
          example: '2021-01-01T00:00:00Z'
          description: Timestamp of when the device was last updated.
    DeviceStatus:
      type: string
      description: >
        The status of the device.

        - Inactive: The miru agent has not yet been installed / authenticated

        - Activating: The miru agent is currently being installed /
        authenticated (should only last for a few seconds)

        - Online: The miru agent has successfully pinged the server within the
        last 60 seconds.

        - Offline: The miru agent has not successfully pinged the server within
        the last 60 seconds (e.g. network issues, device is powered off, etc.)
      enum:
        - inactive
        - activating
        - online
        - offline
      x-enum-varnames:
        - DEVICE_STATUS_INACTIVE
        - DEVICE_STATUS_ACTIVATING
        - DEVICE_STATUS_ONLINE
        - DEVICE_STATUS_OFFLINE
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
      description: The API key to use for authentication.

````