---
updatedAt: 2026-04-27T08:15:38.000Z
agentTools:
  projectIndex: https://docs.youlend.com/llms.txt
---

# Create an embed token.

This endpoint is used to create short-lived tokens to use with Embedded Components. Please see the [Embedded Components](https://docs.youlend.com/docs/embedded-components) guide for details on how to get started.

<br />

# OpenAPI definition

```json
{
  "openapi": "3.0.1",
  "info": {
    "title": "Onboarding",
    "description": "Through this API you can can initiate the process of onboarding a borrower with YouLend",
    "contact": {
      "name": "Mark Ufland",
      "email": "mark.ufland@youlend.com"
    },
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://partners.staging-youlendapi.com/onboarding"
    }
  ],
  "paths": {
    "/Embed/token": {
      "post": {
        "tags": [
          "Embedded Components"
        ],
        "summary": "Create an embed token.",
        "parameters": [
          {
            "name": "api-version",
            "in": "header",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GetTokenRequestModel"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/GetTokenRequestModel"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/GetTokenRequestModel"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Auth0TokenResponse"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/Auth0TokenResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              },
              "application/xml": {
                "schema": {
                  "$ref": "#/components/schemas/ProblemDetails"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Auth0TokenResponse": {
        "type": "object",
        "properties": {
          "accessToken": {
            "type": "string",
            "nullable": true
          },
          "expiresIn": {
            "type": "integer",
            "format": "int32"
          },
          "tokenType": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "GetTokenRequestModel": {
        "required": [
          "thirdPartyCustomerId"
        ],
        "type": "object",
        "properties": {
          "thirdPartyCustomerId": {
            "minLength": 1,
            "type": "string",
            "description": "Your unique identifier for this merchant."
          }
        },
        "additionalProperties": false
      },
      "ProblemDetails": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "nullable": true
          },
          "title": {
            "type": "string",
            "nullable": true
          },
          "status": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "detail": {
            "type": "string",
            "nullable": true
          },
          "instance": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": {}
      }
    },
    "securitySchemes": {
      "oauth2": {
        "type": "oauth2",
        "flows": {
          "clientCredentials": {
            "tokenUrl": "https://youlend-stag.eu.auth0.com/oauth/token",
            "scopes": {}
          }
        }
      }
    }
  },
  "security": [
    {
      "oauth2": []
    }
  ]
}
```