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

# List Services

> List all configured services and their current state.



## OpenAPI

````yaml /sprites/api/openapi.json get /v1/sprites/{name}/services
openapi: 3.1.0
info:
  title: Sprites API
  version: 0.1.12
  x-sprite-env-version: v0.0.1-rc48
servers:
  - url: https://api.sprites.dev
security: []
paths:
  /v1/sprites/{name}/services:
    get:
      tags:
        - Services
      summary: List Services
      description: List all configured services and their current state.
      operationId: sprite_env_list__services
      parameters:
        - in: path
          name: name
          required: true
          schema:
            type: string
      responses:
        '200':
          content:
            application/json:
              example:
                - args:
                    - '-D'
                    - /var/lib/postgresql/data
                  cmd: postgres
                  http_port: null
                  name: postgres
                  needs: []
                  state:
                    name: postgres
                    pid: 1234
                    started_at: '2026-01-05T08:00:00Z'
                    status: running
                - args:
                    - '-m'
                    - http.server
                    - '8000'
                  cmd: python
                  http_port: 8000
                  name: webapp
                  needs:
                    - postgres
                  state:
                    name: webapp
                    pid: 1567
                    started_at: '2026-01-05T08:01:00Z'
                    status: running
              schema:
                items:
                  $ref: '#/components/schemas/ServiceResponse'
                type: array
          description: Success
        '404':
          description: Not Found - Resource not found
        '500':
          description: Internal Server Error
      security:
        - bearerAuth: []
components:
  schemas:
    ServiceResponse:
      example:
        args:
          - '-m'
          - http.server
          - '8000'
        cmd: python
        http_port: 8000
        name: webapp
        needs:
          - postgres
        state:
          name: webapp
          pid: 1567
          started_at: '2026-01-05T08:01:00Z'
          status: running
      properties:
        args:
          description: Command arguments
          items:
            type: string
          type: array
        cmd:
          description: Command to execute
          type: string
        http_port:
          description: HTTP port for proxy routing
          type:
            - integer
            - 'null'
        name:
          description: Service name
          type: string
        needs:
          description: Service dependencies
          items:
            type: string
          type: array
        state:
          description: Current runtime state
          oneOf:
            - $ref: '#/components/schemas/ServiceState'
            - type: 'null'
      required:
        - name
        - cmd
        - args
        - needs
      type: object
    ServiceState:
      example:
        name: webapp
        pid: 1567
        started_at: '2026-01-05T08:01:00Z'
        status: running
      properties:
        error:
          description: Error message if failed
          type: string
        name:
          description: Service name
          type: string
        pid:
          description: Process ID when running
          type: integer
        started_at:
          description: ISO 8601 timestamp
          type: string
        status:
          description: '`stopped`, `starting`, `running`, `stopping`, or `failed`'
          type: string
      required:
        - name
        - status
      type: object
  securitySchemes:
    bearerAuth:
      scheme: bearer
      type: http

````