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

# Get SP metadata

> Returns the Service Provider (SP) metadata XML for the connection. Upload
this document (or its URL) to the Identity Provider when configuring the
SAML application. Public; no authentication required.




## OpenAPI

````yaml get /v1/session/login/saml/{provider_id}/{connection_id}/metadata
openapi: 3.1.1
info:
  title: Prelude Auth Frontend API
  version: 0.0.1
  description: The Prelude Frontend API for Authentication and Session Management
  contact:
    email: support@prelude.so
servers:
  - url: https://{appId}.session.prelude.dev
    description: Production server
    variables:
      appId:
        default: changeme
        description: The appID
security: []
tags:
  - name: Login OTP
    description: Login and step-up via OTP (phone or email)
  - name: Login Email Password
    description: Login via email and password
  - name: Login OAuth
    description: Login via OAuth providers
  - name: Login SAML
    description: Login via SAML 2.0 SSO connections (Okta, Google Workspace)
  - name: Login Finalize
    description: Finalize a login flow and create a session
  - name: Login Migration
    description: Migrate sessions from a legacy authentication system
  - name: Session
    description: Session refresh and revocation
  - name: Session Management
    description: Authenticated session and identifier management
  - name: Step-Up
    description: Step-up authentication flow
  - name: Well-Known
    description: Public key discovery endpoints
  - name: Password
    description: Password compliancy and change password
  - name: Passkey Login
    description: >-
      Primary-factor (passwordless) sign-in via WebAuthn discoverable
      credentials
  - name: Passkey Management
    description: >-
      Register / list / rename / delete the authenticated user's passkey
      credentials
paths:
  /v1/session/login/saml/{provider_id}/{connection_id}/metadata:
    get:
      tags:
        - Login SAML
      summary: Get SP metadata
      description: >
        Returns the Service Provider (SP) metadata XML for the connection.
        Upload

        this document (or its URL) to the Identity Provider when configuring the

        SAML application. Public; no authentication required.
      operationId: samlMetadata
      parameters:
        - $ref: '#/components/parameters/samlProviderIDParam'
        - $ref: '#/components/parameters/samlConnectionIDParam'
      responses:
        '200':
          description: OK
          content:
            application/samlmetadata+xml:
              schema:
                type: string
                format: binary
        '404':
          description: Not Found (connection not configured)
        '500':
          description: Internal Server Error
components:
  parameters:
    samlProviderIDParam:
      name: provider_id
      in: path
      required: true
      schema:
        type: string
        examples:
          - okta
          - google
      description: The SAML provider identifier (`okta` or `google`).
    samlConnectionIDParam:
      name: connection_id
      in: path
      required: true
      schema:
        type: string
        examples:
          - samlc_01jqebhswje1ka1z7ahr9rfsgt
      description: The SAML connection identifier (prefixed with `samlc_`).

````