DevArmor Diagrams API

The diagrams API from DevArmor — 8 operation(s) for diagrams.

Operations 14

GET /projects/{project_id}/threat-models/{threat_model_id}/versions/{version}/diagrams/generate Generate a threat model architecture diagram #
POST /projects/{project_id}/threat-models/{threat_model_id}/versions/{version}/diagrams/generate Generate and store a threat model architecture diagram #
POST /projects/{project_id}/threat-models/{threat_model_id}/versions/{version}/diagrams Create a diagram in a project #
GET /projects/{project_id}/threat-models/{threat_model_id}/versions/{version}/diagrams List diagram in a project #
PUT /projects/{project_id}/threat-models/{threat_model_id}/versions/{version}/diagrams/{diagram_id} Update a diagram in a project #
GET /projects/{project_id}/diagrams/generate Generate a project architecture diagram #
POST /projects/{project_id}/diagrams/generate Generate and store a project architecture diagram #
POST /projects/{project_id}/diagrams Create a project diagram #
GET /projects/{project_id}/diagrams List diagrams in a project #
PUT /projects/{project_id}/diagrams/{diagram_id} Update a project diagram #
GET /projects/{project_id}/diagrams/{resource_id} Get a diagram from a project #
DELETE /projects/{project_id}/diagrams/{resource_id} Delete a diagram from a project #
GET /projects/{project_id}/threat-models/{threat_model_id}/versions/{version}/diagrams/{resource_id} Get a diagram from a project #
DELETE /projects/{project_id}/threat-models/{threat_model_id}/versions/{version}/diagrams/{resource_id} Delete a threat model diagram from a project #

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/devarmor:devarmor-diagrams-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

devarmor-diagrams-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: DevArmor Security Reviews Diagrams API
  version: 1.14.0
tags:
- name: diagrams
paths:
  /projects/{project_id}/threat-models/{threat_model_id}/versions/{version}/diagrams/generate:
    get:
      tags:
      - diagrams
      summary: Generate a threat model architecture diagram
      operationId: generate_threat_model_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      - name: version
        in: path
        required: true
        schema:
          type: string
          title: Version
      - name: threat_model_id
        in: path
        required: true
        schema:
          type: string
          title: Threat Model Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GenerateDiagram'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
    post:
      tags:
      - diagrams
      summary: Generate and store a threat model architecture diagram
      operationId: generate_and_store_threat_model_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      - name: version
        in: path
        required: true
        schema:
          type: string
          title: Version
      - name: threat_model_id
        in: path
        required: true
        schema:
          type: string
          title: Threat Model Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ParseDiagramRequest'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Diagram'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /projects/{project_id}/threat-models/{threat_model_id}/versions/{version}/diagrams:
    post:
      tags:
      - diagrams
      summary: Create a diagram in a project
      operationId: create_project_threat_model_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      - name: version
        in: path
        required: true
        schema:
          type: string
          title: Version
      - name: threat_model_id
        in: path
        required: true
        schema:
          type: string
          title: Threat Model Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DiagramCreate'
      responses:
        '201':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Diagram'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
    get:
      tags:
      - diagrams
      summary: List diagram in a project
      operationId: list_project_threat_model_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      - name: version
        in: path
        required: true
        schema:
          type: string
          title: Version
      - name: threat_model_id
        in: path
        required: true
        schema:
          type: string
          title: Threat Model Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Diagram'
                title: Response List Project Threat Model Diagram
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /projects/{project_id}/threat-models/{threat_model_id}/versions/{version}/diagrams/{diagram_id}:
    put:
      tags:
      - diagrams
      summary: Update a diagram in a project
      operationId: update_project_threat_model_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: diagram_id
        in: path
        required: true
        schema:
          type: string
          title: Diagram Id
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      - name: version
        in: path
        required: true
        schema:
          type: string
          title: Version
      - name: threat_model_id
        in: path
        required: true
        schema:
          type: string
          title: Threat Model Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DiagramUpdate'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Diagram'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /projects/{project_id}/diagrams/generate:
    get:
      tags:
      - diagrams
      summary: Generate a project architecture diagram
      operationId: generate_project_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      - name: threat_model_id
        in: query
        required: true
        schema:
          type: integer
          title: Threat Model Id
      - name: version
        in: query
        required: true
        schema:
          type: string
          title: Version
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GenerateDiagram'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
    post:
      tags:
      - diagrams
      summary: Generate and store a project architecture diagram
      operationId: generate_and_store_project_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/GenerateProjectDiagramRequest'
      responses:
        '201':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Diagram'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /projects/{project_id}/diagrams:
    post:
      tags:
      - diagrams
      summary: Create a project diagram
      operationId: create_project_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DiagramCreate'
      responses:
        '201':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Diagram'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
    get:
      tags:
      - diagrams
      summary: List diagrams in a project
      operationId: list_project_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Diagram'
                title: Response List Project Diagram
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /projects/{project_id}/diagrams/{diagram_id}:
    put:
      tags:
      - diagrams
      summary: Update a project diagram
      operationId: update_project_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: diagram_id
        in: path
        required: true
        schema:
          type: string
          title: Diagram Id
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DiagramUpdate'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Diagram'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /projects/{project_id}/diagrams/{resource_id}:
    get:
      tags:
      - diagrams
      summary: Get a diagram from a project
      operationId: get_project_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: resource_id
        in: path
        required: true
        schema:
          type: string
          title: Resource Id
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Diagram'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
    delete:
      tags:
      - diagrams
      summary: Delete a diagram from a project
      operationId: delete_project_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: resource_id
        in: path
        required: true
        schema:
          type: string
          title: Resource Id
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      - name: force
        in: query
        required: false
        schema:
          type: boolean
          default: false
          title: Force
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DiagramDelete'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
  /projects/{project_id}/threat-models/{threat_model_id}/versions/{version}/diagrams/{resource_id}:
    get:
      tags:
      - diagrams
      summary: Get a diagram from a project
      operationId: get_project_threat_model_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: resource_id
        in: path
        required: true
        schema:
          type: string
          title: Resource Id
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      - name: version
        in: path
        required: true
        schema:
          type: string
          title: Version
      - name: threat_model_id
        in: path
        required: true
        schema:
          type: string
          title: Threat Model Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Diagram'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
    delete:
      tags:
      - diagrams
      summary: Delete a threat model diagram from a project
      operationId: delete_project_threat_model_diagram
      security:
      - APIGatewayAuth: []
      parameters:
      - name: resource_id
        in: path
        required: true
        schema:
          type: string
          title: Resource Id
      - name: project_id
        in: path
        required: true
        schema:
          type: string
          title: Project Id
      - name: version
        in: path
        required: true
        schema:
          type: string
          title: Version
      - name: threat_model_id
        in: path
        required: true
        schema:
          type: string
          title: Threat Model Id
      - name: force
        in: query
        required: false
        schema:
          type: boolean
          default: false
          title: Force
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DiagramDelete'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    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
        ctx:
          type: object
          title: Context
      type: object
      required:
      - loc
      - msg
      - type
      title: ValidationError
    UserRole:
      type: string
      enum:
      - admin
      - customer_support
      title: UserRole
    DiagramType:
      type: string
      enum:
      - graphviz
      - mermaid
      - plantuml
      - svg
      title: DiagramType
    GenerateDiagram:
      properties:
        source:
          type: string
          title: Source
        meta_data:
          items:
            $ref: '#/components/schemas/DiagramNode'
          type: array
          title: Meta Data
      type: object
      required:
      - source
      - meta_data
      title: GenerateDiagram
    DiagramDelete:
      properties:
        symbolic_name:
          type: string
          pattern: ^[0-9a-z-]+$
          title: Symbolic Name
        title:
          type: string
          title: Title
        description:
          anyOf:
          - type: string
          - type: 'null'
          title: Description
        link:
          anyOf:
          - type: string
            maxLength: 2083
            minLength: 1
            format: uri
          - type: 'null'
          title: Link
        type:
          anyOf:
          - $ref: '#/components/schemas/DiagramType'
          - type: 'null'
        source:
          anyOf:
          - type: string
          - type: 'null'
          title: Source
        completed_at:
          anyOf:
          - type: string
            format: date-time
          - type: 'null'
          title: Completed At
      type: object
      required:
      - symbolic_name
      - title
      title: DiagramDelete
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ParseDiagramRequest:
      properties:
        title:
          type: string
          title: Title
        description:
          type: string
          title: Description
      type: object
      required:
      - title
      - description
      title: ParseDiagramRequest
    DiagramNode:
      properties:
        node_id:
          type: string
          title: Node Id
        entity_type:
          type: string
          title: Entity Type
        entity_id:
          type: integer
          title: Entity Id
      type: object
      required:
      - node_id
      - entity_type
      - entity_id
      title: DiagramNode
    Diagram:
      properties:
        symbolic_name:
          type: string
          pattern: ^[0-9a-z-]+$
          title: Symbolic Name
        title:
          type: string
          title: Title
        description:
          anyOf:
          - type: string
          - type: 'null'
          title: Description
        link:
          anyOf:
          - type: string
            maxLength: 2083
            minLength: 1
            format: uri
          - type: 'null'
          title: Link
        type:
          anyOf:
          - $ref: '#/components/schemas/DiagramType'
          - type: 'null'
        source:
          anyOf:
          - type: string
          - type: 'null'
          title: Source
        completed_at:
          anyOf:
          - type: string
            format: date-time
          - type: 'null'
          title: Completed At
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        id:
          type: integer
          title: Id
        project:
          $ref: '#/components/schemas/Project'
        threat_model_versions:
          items:
            type: string
            pattern: ^\d+(\.\d+)*$
          type: array
          title: Threat Model Versions
        threat_model_id:
          anyOf:
          - type: integer
          - type: 'null'
          title: Threat Model Id
        blob:
          anyOf:
          - $ref: '#/components/schemas/Blob'
          - type: 'null'
        design_review_ids:
          items:
            type: integer
          type: array
          title: Design Review Ids
      type: object
      required:
      - symbolic_name
      - title
      - id
      - project
      - threat_model_versions
      - design_review_ids
      title: Diagram
    Project:
      properties:
        symbolic_name:
          type: string
          pattern: ^[0-9a-z-]+$
          title: Symbolic Name
        title:
          type: string
          title: Title
        default:
          type: boolean
          title: Default
          default: false
        description:
          anyOf:
          - type: string
          - type: 'null'
          title: Description
        use_memory:
          type: boolean
          title: Use Memory
          default: true
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        id:
          type: integer
          title: Id
        owner_user:
          $ref: '#/components/schemas/User'
        memory_effective:
          anyOf:
          - type: boolean
          - type: 'null'
          title: Memory Effective
        memory_effective_reason:
          anyOf:
          - type: string
          - type: 'null'
          title: Memory Effective Reason
      type: object
      required:
      - symbolic_name
      - title
      - id
      - owner_user
      title: Project
    User:
      properties:
        email:
          type: string
          title: Email
        name:
          type: string
          title: Name
        state:
          $ref: '#/components/schemas/UserState'
          default: active
        roles:
          items:
            $ref: '#/components/schemas/UserRole'
          type: array
          title: Roles
          default: []
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        id:
          type: integer
          title: Id
      type: object
      required:
      - email
      - name
      - id
      title: User
    Blob:
      properties:
        name:
          type: string
          title: Name
        is_uploaded:
          type: boolean
          title: Is Uploaded
        file_id:
          type: string
          format: uuid
          title: File Id
        mime_type:
          type: string
          title: Mime Type
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        id:
          type: integer
          title: Id
        url:
          anyOf:
          - type: string
          - type: 'null'
          title: Url
      type: object
      required:
      - name
      - is_uploaded
      - file_id
      - mime_type
      - id
      title: Blob
    DiagramUpdate:
      properties:
        symbolic_name:
          type: 'null'
          title: Symbolic Name
        title:
          anyOf:
          - type: string
          - type: 'null'
          title: Title
        description:
          anyOf:
          - type: string
          - type: 'null'
          title: Description
        link:
          anyOf:
          - type: string
            maxLength: 2083
            minLength: 1
            format: uri
          - type: 'null'
          title: Link
        type:
          anyOf:
          - $ref: '#/components/schemas/DiagramType'
          - type: 'null'
        source:
          anyOf:
          - type: string
          - type: 'null'
          title: Source
        completed_at:
          type: 'null'
          title: Completed At
        blob_id:
          anyOf:
          - type: integer
          - type: 'null'
          title: Blob Id
      type: object
      title: DiagramUpdate
    DiagramCreate:
      properties:
        symbolic_name:
          type: 'null'
          title: Symbolic Name
        title:
          type: string
          title: Title
        description:
          anyOf:
          - type: string
          - type: 'null'
          title: Description
        link:
          anyOf:
          - type: string
            maxLength: 2083
            minLength: 1
            format: uri
          - type: 'null'
          title: Link
        type:
          anyOf:
          - $ref: '#/components/schemas/DiagramType'
          - type: 'null'
        source:
          anyOf:
          - type: string
          - type: 'null'
          title: Source
        completed_at:
          type: 'null'
          title: Completed At
        blob_id:
          anyOf:
          - type: integer
          - type: 'null'
          title: Blob Id
        threat_model_versions:
          anyOf:
          - items:
              type: string
              pattern: ^\d+(\.\d+)*$
            type: array
          - type: 'null'
          title: Threat Model Versions
        threat_model_id:
          anyOf:
          - type: integer
          - type: 'null'
          title: Threat Model Id
        design_review_ids:
          anyOf:
          - items:
              type: integer
            type: array
          - type: 'null'
          title: Design Review Ids
      type: object
      required:
      - title
      title: DiagramCreate
    UserState:
      type: string
      enum:
      - active
      - inactive
      - pending_org_approval
      title: UserState
    GenerateProjectDiagramRequest:
      properties:
        title:
          type: string
          title: Title
        description:
          type: string
          title: Description
        threat_model_id:
          type: integer
          title: Threat Model Id
        version:
          type: string
          title: Version
      type: object
      required:
      - title
      - description
      - threat_model_id
      - version
      title: GenerateProjectDiagramRequest
  securitySchemes:
    APIGatewayAuth:
      type: http
      scheme: bearer