> ## Documentation Index
> Fetch the complete documentation index at: https://uiform-codex-generated-frontend-snippets.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Restore Edge Version

Restore a workflow edge version into the current workflow draft.

```python Python theme={null}
edge_version_id = "egv_abc123"
print(edge_version_id)
```

```typescript TypeScript theme={null}
const edgeVersionId = "egv_abc123";
console.log(edgeVersionId);
```

```go Go theme={null}
edgeVersionID := "egv_abc123"
_ = edgeVersionID
```

```java Java theme={null}
String edgeVersionId = "egv_abc123";
System.out.println(edgeVersionId);
```

```bash cURL theme={null}
curl -X POST "https://api.retab.com/v1/workflows/edges/versions/egv_abc123/restore?workflow_id=wf_abc123" \
  -H "Authorization: Bearer $RETAB_API_KEY"
```


## OpenAPI

````yaml POST /v1/workflows/edges/versions/{edge_version_id}/restore
openapi: 3.1.0
info:
  title: FastAPI
  version: 0.1.0
servers:
  - url: https://api.retab.com
security: []
paths:
  /v1/workflows/edges/versions/{edge_version_id}/restore:
    post:
      tags:
        - Workflows
        - Workflow Edges
      summary: Restore Edge Version
      operationId: restore_edge_version
      parameters:
        - in: path
          name: edge_version_id
          required: true
          schema:
            type: string
            title: Edge Version Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowEdge'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    WorkflowEdge:
      properties:
        id:
          type: string
          title: Id
        workflow_id:
          type: string
          title: Workflow Id
          description: Foreign key to workflow
        source_block:
          type: string
          title: Source Block
          description: ID of the source block
        target_block:
          type: string
          title: Target Block
          description: ID of the target block
        source_handle:
          anyOf:
            - type: string
            - type: 'null'
          title: Source Handle
          description: Output handle on source block
        target_handle:
          anyOf:
            - type: string
            - type: 'null'
          title: Target Handle
          description: Input handle on target block
        updated_at:
          type: string
          format: date-time
          title: Updated At
      type: object
      required:
        - id
        - source_block
        - target_block
        - updated_at
        - workflow_id
      title: WorkflowEdge
      description: Public live workflow edge object.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
          default: []
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
          default: null
        ctx:
          type: object
          title: Context
          default: {}
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````