PhotoPrism Services API

The Services API from PhotoPrism — 4 operation(s) for services.

Operations 7

GET /api/v1/services finds services and returns them as JSON #
POST /api/v1/services creates a new remote service account configuration #
DELETE /api/v1/services/{id} removes a remote service account configuration #
GET /api/v1/services/{id} returns the specified remote service account configuration as JSON #
PUT /api/v1/services/{id} updates a remote account configuration #
GET /api/v1/services/{id}/folders returns folders that belong to a remote service account #
POST /api/v1/services/{id}/upload uploads files to the selected service account #

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/photoprism:photoprism-services-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

photoprism-services-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  contact: {}
  description: 'API request bodies and responses are usually JSON-encoded, except for binary data and some of the OAuth2 endpoints. Note that the `Content-Type` header must be set to `application/json` for this, as the request may otherwise fail with error 400.

    When clients have a valid access token, e.g. obtained through the `POST /api/v1/session` or `POST /api/v1/oauth/token` endpoint, they can use a standard Bearer Authorization header to authenticate their requests. Submitting the access token with a custom `X-Auth-Token` header is supported as well.'
  title: PhotoPrism Services API
  version: v1
servers:
- url: https://demo.photoprism.app
security:
- BearerAuth: []
tags:
- name: Services
paths:
  /api/v1/services:
    get:
      operationId: SearchServices
      parameters:
      - description: maximum number of results
        in: query
        name: count
        required: true
        schema:
          type: integer
          maximum: 100000
          minimum: 1
      responses:
        '200':
          description: OK
          headers:
            X-Count:
              description: The actual number of services returned
              schema:
                type: number
            X-Limit:
              description: The limit of the number of services to be returned
              schema:
                type: number
            X-Offset:
              description: The offset that was used
              schema:
                type: number
          content:
            application/json:
              schema:
                items:
                  $ref: '#/components/schemas/entity.Service'
                type: array
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '429':
          description: Too Many Requests
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
      summary: finds services and returns them as JSON
      tags:
      - Services
    post:
      operationId: AddService
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/entity.Service'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '413':
          description: Request Entity Too Large
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '429':
          description: Too Many Requests
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
      summary: creates a new remote service account configuration
      tags:
      - Services
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/form.Service'
        description: properties of the service to be created
        required: true
  /api/v1/services/{id}:
    delete:
      operationId: DeleteService
      parameters:
      - description: service id
        in: path
        name: id
        required: true
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/entity.Service'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '429':
          description: Too Many Requests
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
      summary: removes a remote service account configuration
      tags:
      - Services
    get:
      operationId: GetService
      parameters:
      - description: service id
        in: path
        name: id
        required: true
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/entity.Service'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '429':
          description: Too Many Requests
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
      summary: returns the specified remote service account configuration as JSON
      tags:
      - Services
    put:
      operationId: UpdateService
      parameters:
      - description: service id
        in: path
        name: id
        required: true
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/entity.Service'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '413':
          description: Request Entity Too Large
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '429':
          description: Too Many Requests
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
      summary: updates a remote account configuration
      tags:
      - Services
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/form.Service'
        description: properties to be updated (only submit values that should be changed)
        required: true
  /api/v1/services/{id}/folders:
    get:
      operationId: GetServiceFolders
      parameters:
      - description: service id
        in: path
        name: id
        required: true
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                items:
                  type: object
                type: array
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '429':
          description: Too Many Requests
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
      summary: returns folders that belong to a remote service account
      tags:
      - Services
  /api/v1/services/{id}/upload:
    post:
      operationId: UploadToService
      parameters:
      - description: service id
        in: path
        name: id
        required: true
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                items:
                  $ref: '#/components/schemas/entity.File'
                type: array
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '413':
          description: Request Entity Too Large
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
        '429':
          description: Too Many Requests
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/i18n.Response'
      summary: uploads files to the selected service account
      tags:
      - Services
components:
  schemas:
    time.Duration:
      format: int64
      type: integer
    entity.File:
      properties:
        AspectRatio:
          type: number
        Chroma:
          type: integer
        Codec:
          type: string
        ColorProfile:
          type: string
        Colors:
          type: string
        CreatedAt:
          type: string
        CreatedIn:
          type: integer
        DeletedAt:
          type: string
        Diff:
          type: integer
        Duration:
          $ref: '#/components/schemas/time.Duration'
        Error:
          type: string
        FPS:
          type: number
        FileType:
          type: string
        Frames:
          type: integer
        HDR:
          type: boolean
        Hash:
          type: string
        Height:
          type: integer
        InstanceID:
          type: string
        Luminance:
          type: string
        MainColor:
          type: string
        MediaID:
          type: string
        MediaType:
          type: string
        MediaUTC:
          type: integer
        Mime:
          type: string
        Missing:
          type: boolean
        ModTime:
          type: integer
        Name:
          type: string
        Orientation:
          type: integer
        OrientationSrc:
          type: string
        OriginalName:
          type: string
        Pages:
          type: integer
        PhotoUID:
          type: string
        Portrait:
          type: boolean
        Primary:
          type: boolean
        Projection:
          type: string
        PublishedAt:
          type: string
        Root:
          type: string
        Sidecar:
          type: boolean
        Size:
          type: integer
        Software:
          type: string
        TakenAt:
          type: string
        TimeIndex:
          type: string
        UID:
          type: string
        UpdatedAt:
          type: string
        UpdatedIn:
          type: integer
        Video:
          type: boolean
        Watermark:
          type: boolean
        Width:
          type: integer
      type: object
    i18n.Response:
      properties:
        code:
          type: integer
        details:
          type: string
        error:
          type: string
        message:
          type: string
        messageId:
          type: string
        messageParams:
          items: {}
          type: array
      type: object
    form.Service:
      properties:
        AccError:
          description: Read only, except that an empty value clears it.
          type: string
        AccKey:
          type: string
        AccName:
          type: string
        AccOwner:
          type: string
        AccPass:
          type: string
        AccShare:
          description: Manual upload enabled, see SharePath, ShareSize, and ShareExpires.
          type: boolean
        AccSync:
          description: Background sync enabled, see SyncDownload and SyncUpload.
          type: boolean
        AccTimeout:
          description: 'Request timeout: default, high, medium, low, none'
          type: string
        AccType:
          type: string
        AccURL:
          type: string
        AccUser:
          type: string
        RetryLimit:
          description: Maximum number of failed requests.
          type: integer
        ShareExpires:
          type: integer
        SharePath:
          type: string
        ShareSize:
          type: string
        SyncDownload:
          type: boolean
        SyncFilenames:
          type: boolean
        SyncInterval:
          type: integer
        SyncPath:
          type: string
        SyncRaw:
          type: boolean
        SyncUpload:
          type: boolean
        SyncYaml:
          description: 'YAML sidecar files: -1 disabled, 0 default (enabled), 1 enabled.'
          type: integer
      type: object
    entity.Service:
      properties:
        AccError:
          type: string
        AccErrors:
          type: integer
        AccName:
          type: string
        AccOwner:
          type: string
        AccShare:
          type: boolean
        AccSync:
          type: boolean
        AccTimeout:
          type: string
        AccType:
          type: string
        AccURL:
          type: string
        AccUser:
          type: string
        CreatedAt:
          type: string
        DeletedAt:
          type: string
        ID:
          type: integer
        RetryLimit:
          type: integer
        ShareExpires:
          type: integer
        SharePath:
          type: string
        ShareSize:
          type: string
        SyncDate:
          $ref: '#/components/schemas/sql.NullTime'
        SyncDownload:
          type: boolean
        SyncFilenames:
          type: boolean
        SyncInterval:
          type: integer
        SyncPath:
          type: string
        SyncRaw:
          type: boolean
        SyncStatus:
          type: string
        SyncUpload:
          type: boolean
        SyncYaml:
          type: integer
        UpdatedAt:
          type: string
      type: object
    sql.NullTime:
      properties:
        time:
          type: string
        valid:
          description: Valid is true if Time is not NULL
          type: boolean
      type: object
  securitySchemes:
    BearerAuth:
      in: header
      name: Authorization
      type: apiKey
externalDocs:
  description: Learn more ›
  url: https://docs.photoprism.app/developer-guide/api/