openapi: 3.1.0 info: title: Undress API description: API for undressing images, face swaps, and animations version: 1.5.0 contact: name: DeepStrip url: https://deepstrip.com/ servers: - url: https://deepstrip.com/api/v1 components: securitySchemes: bearerAuth: type: http scheme: bearer bearerFormat: JWT schemas: UndressRequest: type: object required: - style properties: source_image: type: string description: Base64 encoded source image in jpeg format. mask: type: string description: "Base64 encoded mask image in png format. Contains two colors: white for undressing regions, black for the rest." automask: type: boolean description: If set to true, mask will be automatically generated. Do not used for style video parent: type: string description: ID of the parent Undress, required to continue the undress video style: type: string description: The model for undressing. enum: [standard, premium, premium_v2, video] body_shape: type: string description: Body shape adjustment (only for premium_v2 style). enum: ["null", fat, skinny, athletic] boobs: type: string description: Breast size adjustment (only for premium_v2 style). enum: ["null", small, large] hair: type: string description: Pubic hair style (only for premium_v2 style). enum: ["null", hairy, shaved] FaceSwapRequest: type: object required: - image - face properties: image: type: string description: Base64 encoded image. face: type: string description: Base64 encoded face image. version: type: string description: Version of the face swap model. enum: [v1, v2] UndressResponse: type: object properties: id: type: string description: Identifier for the job. FaceSwapResponse: type: object properties: id: type: string description: Identifier for the job. ErrorResponse: type: object properties: error: type: string errors: type: array items: type: string UndressResultResponse: type: object properties: status: type: string description: Status of the undress job. enum: [pending, completed, failed] image: type: string description: URL of the generated image, if the job is completed. DEPRECATED result: type: string description: URL of the generated result, if the job is completed. FaceSwapResultResponse: type: object properties: status: type: string description: Status of the face swap job. enum: [pending, completed, failed] image: type: string description: URL of the generated image, if the job is completed. FaceSwapVideoAnalyzeRequest: type: object required: - video_url properties: video_url: type: string description: HTTPS URL of the video to analyze. preview: type: boolean description: Whether to create a preview (shorter) version. version: type: string description: Version of the face swap model. enum: [v1, v2] FaceSwapVideoAnalyzeResponse: type: object properties: price: type: number description: Calculated price for the face swap video. version: type: string description: Version that will be used. enum: [v1, v2] preview: type: boolean description: Whether this is a preview version. FaceSwapVideoRequest: type: object properties: video_url: type: string description: HTTPS URL of the video to process. face_url: type: string description: HTTPS URL of the face image. preview: type: boolean description: Whether to create a preview version. version: type: string description: Version of the face swap model. enum: [v1, v2] FaceSwapVideoResponse: type: object properties: id: type: string description: Identifier for the face swap video job. status: type: string description: Initial status of the job. message: type: string description: Additional information about the job. FaceSwapVideoStatusResponse: type: object properties: id: type: string description: Identifier for the face swap video job. status: type: string description: Status of the face swap video job. enum: [initial, sent, processing, completed, failed] progress: type: number description: Progress percentage of the processing. step: type: string description: Current processing step. enum: [queued, downloading, fps, analysing, working, sound, reencoding_step_1, reencoding_step_2, postprocessing, uploading] result_url: type: string description: URL of the processed video, if completed. error_details: type: object description: Error information if the job failed. AnimationRequest: type: object required: - source_image properties: source_image: type: string description: Base64 encoded data URI in jpeg, png, or webp format (e.g., data:image/jpeg;base64,/9j/4AAQ...). template_id: type: integer description: ID of the animation template to use. Get available templates from /animation_templates endpoint. preset_id: type: integer description: "Deprecated: use template_id instead. ID of the animation template." AnimationResponse: type: object properties: id: type: string description: Identifier for the animation job. AnimationResultResponse: type: object properties: status: type: string description: Status of the animation job. enum: [pending, completed, failed] result: type: string description: URL of the generated video, if the job is completed. AnimationTemplateListResponse: type: array items: type: object properties: id: type: integer description: Template ID to use with the animation API. name: type: string description: English name of the template. name_de: type: string description: German name (falls back to English if not set). name_es: type: string description: Spanish name (falls back to English if not set). name_pt: type: string description: Portuguese name (falls back to English if not set). name_fr: type: string description: French name (falls back to English if not set). name_ru: type: string description: Russian name (falls back to English if not set). name_zh: type: string description: Chinese name (falls back to English if not set). security: - bearerAuth: [] paths: /undress: post: summary: Create an undress job operationId: createUndress requestBody: required: true content: application/json: schema: $ref: "#/components/schemas/UndressRequest" responses: "201": description: Job created successfully. content: application/json: schema: $ref: "#/components/schemas/UndressResponse" "400": description: Invalid parameters or no credits. content: application/json: schema: $ref: "#/components/schemas/ErrorResponse" /face_swap_videos/analyze: post: summary: Analyze a video for face swap processing operationId: analyzeFaceSwapVideo requestBody: required: true content: application/json: schema: $ref: "#/components/schemas/FaceSwapVideoAnalyzeRequest" responses: "200": description: Analysis completed successfully. content: application/json: schema: $ref: "#/components/schemas/FaceSwapVideoAnalyzeResponse" "400": description: Invalid parameters or URL. content: application/json: schema: $ref: "#/components/schemas/ErrorResponse" "422": description: Analysis failed due to video constraints. content: application/json: schema: type: object properties: error: type: string example: "ANALYSIS_FAILED" details: type: string example: "too_large" "500": description: Internal server error. /face_swap_videos: post: summary: Create a face swap video job operationId: createFaceSwapVideo requestBody: required: true content: application/json: schema: $ref: "#/components/schemas/FaceSwapVideoRequest" multipart/form-data: schema: $ref: "#/components/schemas/FaceSwapVideoRequest" responses: "201": description: Job created successfully. content: application/json: schema: $ref: "#/components/schemas/FaceSwapVideoResponse" "400": description: Invalid parameters, files, or URLs. content: application/json: schema: $ref: "#/components/schemas/ErrorResponse" "500": description: Internal server error. /face_swap_videos/{id}: get: summary: Get the status of a face swap video job operationId: getFaceSwapVideoStatus parameters: - name: id in: path required: true schema: type: string description: Identifier of the face swap video job. responses: "200": description: Current status of the face swap video job. content: application/json: schema: $ref: "#/components/schemas/FaceSwapVideoStatusResponse" "404": description: Job not found. content: application/json: schema: $ref: "#/components/schemas/ErrorResponse" "500": description: Internal server error. /undress/{id}: get: summary: Get the result of an undress job operationId: getUndressResult parameters: - name: id in: path required: true schema: type: string description: Identifier of the undress job. responses: "200": description: Status or result of the undress job. content: application/json: schema: $ref: "#/components/schemas/UndressResultResponse" "404": description: Job not found. content: application/json: schema: $ref: "#/components/schemas/ErrorResponse" /face_swaps: post: summary: Create a face swap job operationId: createFaceSwap requestBody: required: true content: application/json: schema: $ref: "#/components/schemas/FaceSwapRequest" responses: "201": description: Job created successfully. content: application/json: schema: $ref: "#/components/schemas/FaceSwapResponse" "400": description: Invalid parameters or no credits. content: application/json: schema: $ref: "#/components/schemas/ErrorResponse" "500": description: Internal server error. /face_swaps/{id}: get: summary: Get the result of a face swap job operationId: getFaceSwapResult parameters: - name: id in: path required: true schema: type: string description: Identifier of the face swap job. responses: "200": description: Status or result of the face swap job. content: application/json: schema: $ref: "#/components/schemas/FaceSwapResultResponse" "404": description: Job not found. content: application/json: schema: $ref: "#/components/schemas/ErrorResponse" /animations: post: summary: Create an animation job operationId: createAnimation requestBody: required: true content: application/json: schema: $ref: "#/components/schemas/AnimationRequest" responses: "201": description: Job created successfully. content: application/json: schema: $ref: "#/components/schemas/AnimationResponse" "400": description: Invalid parameters or no credits. content: application/json: schema: $ref: "#/components/schemas/ErrorResponse" /animations/{id}: get: summary: Get the result of an animation job operationId: getAnimationResult parameters: - name: id in: path required: true schema: type: string description: Identifier of the animation job. responses: "200": description: Status or result of the animation job. content: application/json: schema: $ref: "#/components/schemas/AnimationResultResponse" "404": description: Job not found. content: application/json: schema: $ref: "#/components/schemas/ErrorResponse" /animation_templates: get: summary: List available animation templates operationId: listAnimationTemplates security: [] responses: "200": description: List of available animation templates. content: application/json: schema: $ref: "#/components/schemas/AnimationTemplateListResponse" /animation_presets: get: summary: "Deprecated: use /animation_templates instead" operationId: listAnimationPresets deprecated: true security: [] responses: "200": description: List of available animation templates (deprecated endpoint). content: application/json: schema: $ref: "#/components/schemas/AnimationTemplateListResponse"