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

# Edit your agent's memory

> Adds an entry to your agent's notes or profile, or removes the entry whose whole text is text. Your agent applies it through its own memory, waking first if it is asleep and waiting first for an update under way to finish: the call returns once it is awake, the edit pending. Read your agent for the edit's outcome: completed, and your agent's next turn reads it, or failed with its memory's refusal (the entry would put the file past its limit, or no entry is the removed text). 422 for an unknown target or action; 400 for text that is blank, over 12000 characters, or not one entry (whitespace at either end, a carriage return, § on a line of its own between two lines, or, for an add, at its end). Refused (409 agent_host_illegal_transition) while your agent is paused, pausing, resuming, being set up or deleted, or lost, and answers 504 agent_host_wake_failed when it did not wake in time; an edit whose wake did not report in stays pending until the next wake.



## OpenAPI

````yaml api-reference/openapi.account.json POST /agent/memory
openapi: 3.1.0
info:
  title: Aether Account & Integrations API
  version: 0.1.0
  description: >-
    Account, billing, and integration-management endpoints used by the Aether
    web app and CLI. Root-mounted; NOT part of the versioned /v1 contract.
servers:
  - url: https://api.runaether.dev
security:
  - bearerAuth: []
paths:
  /agent/memory:
    post:
      tags:
        - agent
      summary: Edit your agent's memory
      description: >-
        Adds an entry to your agent's notes or profile, or removes the entry
        whose whole text is text. Your agent applies it through its own memory,
        waking first if it is asleep and waiting first for an update under way
        to finish: the call returns once it is awake, the edit pending. Read
        your agent for the edit's outcome: completed, and your agent's next turn
        reads it, or failed with its memory's refusal (the entry would put the
        file past its limit, or no entry is the removed text). 422 for an
        unknown target or action; 400 for text that is blank, over 12000
        characters, or not one entry (whitespace at either end, a carriage
        return, § on a line of its own between two lines, or, for an add, at its
        end). Refused (409 agent_host_illegal_transition) while your agent is
        paused, pausing, resuming, being set up or deleted, or lost, and answers
        504 agent_host_wake_failed when it did not wake in time; an edit whose
        wake did not report in stays pending until the next wake.
      operationId: editAgentMemory
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EditAgentMemoryRequest'
        required: true
      responses:
        '202':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AgentMemoryEdit'
          description: Accepted
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          description: Bad Request
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          description: Unauthorized
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrgAuthorizationErrorResponse'
          description: Forbidden
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          description: Not Found
        '409':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          description: Conflict
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          description: Unprocessable Entity
        '500':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          description: Internal Server Error
        '504':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          description: Gateway Timeout
components:
  schemas:
    EditAgentMemoryRequest:
      additionalProperties: false
      properties:
        action:
          description: 'add: a new entry; remove: the entry whose whole text is text.'
          enum:
            - add
            - remove
          type: string
        target:
          description: 'notes: your agent''s notes; profile: what it keeps about you.'
          enum:
            - notes
            - profile
          type: string
        text:
          description: >-
            One entry: not blank, at most 12000 characters, with no whitespace
            at either end, no carriage return, and no § on a line of its own
            between two lines; an added entry does not end with one either.
          type: string
      required:
        - target
        - action
        - text
      type: object
    AgentMemoryEdit:
      additionalProperties: false
      properties:
        action:
          description: 'add: a new entry; remove: the entry whose whole text is the edit''s.'
          enum:
            - add
            - remove
          type: string
        completed_at:
          description: When the edit was applied or refused; absent while pending.
          format: date-time
          type: string
        failure:
          description: >-
            Why the edit was refused: the entry would put the file past its
            limit, no entry is the removed text, or the host could not apply it.
            Present on a failed edit.
          type: string
        id:
          format: uuid
          type: string
        issued_at:
          format: date-time
          type: string
        state:
          description: >-
            pending: your agent has not applied it yet, or has not woken for it;
            completed: applied, and your agent's next turn reads it; failed:
            your agent's memory refused it, for failure.
          enum:
            - pending
            - completed
            - failed
          type: string
        target:
          description: 'notes: your agent''s notes; profile: what it keeps about you.'
          enum:
            - notes
            - profile
          type: string
        text:
          type: string
      required:
        - id
        - target
        - action
        - text
        - state
        - issued_at
      type: object
    ErrorResponse:
      additionalProperties: false
      properties:
        code:
          type: string
        error:
          minLength: 1
          type: string
        errors:
          items:
            $ref: '#/components/schemas/ErrorDetail'
          type: array
      required:
        - error
      type: object
    OrgAuthorizationErrorResponse:
      additionalProperties: false
      properties:
        code:
          enum:
            - org_membership_required
            - org_role_insufficient
            - org_suspended
            - account_deleting
          type: string
        error:
          minLength: 1
          type: string
      required:
        - error
        - code
      type: object
    ErrorDetail:
      additionalProperties: false
      properties:
        location:
          description: >-
            Where the error occurred, e.g. 'body.items[3].tags' or
            'path.thing-id'
          type: string
        message:
          description: Error message text
          type: string
        value:
          description: The value at the given location
      type: object
  securitySchemes:
    bearerAuth:
      bearerFormat: JWT
      scheme: bearer
      type: http

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.