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

# Get pipeline

> Returns a pipeline by its slug.



## OpenAPI

````yaml /api-reference/openapi.json get /workspaces/{workspaceSlug}/pipelines/{pipelineSlug}/
openapi: 3.1.0
info:
  title: Nvisy API
  summary: Document processing and annotation platform
  description: >-
    Nvisy provides intelligent document processing, annotation, and analysis
    capabilities. This API enables document upload, OCR processing, embedding
    generation, and semantic search across your document collections.
  termsOfService: https://nvisy.com/legal/terms-of-service
  contact:
    name: Nvisy Support
    url: https://nvisy.com
    email: hello@nvisy.com
  license:
    name: Proprietary
    url: https://nvisy.com/license
  version: 0.1.0
servers: []
security: []
tags:
  - name: Accounts
    description: Account management and profile operations
  - name: Authentication
    description: Login, signup, and token management
  - name: Workspaces
    description: Workspace creation and management
  - name: Files
    description: File upload, download, and management
  - name: Members
    description: Workspace member management
  - name: Invites
    description: Workspace invitation handling
  - name: API Tokens
    description: API token management
  - name: Connections
    description: External provider connections
  - name: Pipelines
    description: Redaction pipeline configuration
  - name: Pipeline Runs
    description: Pipeline run execution and review
  - name: Policies
    description: Redaction policy configuration
  - name: Webhooks
    description: Webhook configuration
  - name: Notifications
    description: Account notification management
  - name: Health
    description: Service health checks
paths:
  /workspaces/{workspaceSlug}/pipelines/{pipelineSlug}/:
    get:
      tags:
        - Pipelines
      summary: Get pipeline
      description: Returns a pipeline by its slug.
      parameters:
        - in: path
          name: workspaceSlug
          description: URL-safe workspace identifier.
          required: true
          schema:
            description: URL-safe workspace identifier.
            type: string
          style: simple
        - in: path
          name: pipelineSlug
          description: URL slug of the pipeline, unique within its workspace.
          required: true
          schema:
            description: URL slug of the pipeline, unique within its workspace.
            type: string
          style: simple
      responses:
        '200':
          description: Pipeline response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Pipeline'
        '401':
          description: >-
            HTTP error response representation with security-conscious design.


            This struct contains all the information needed to serialize an
            error

            response, including the error name, message, HTTP status code,
            resource

            information, and user-friendly messages.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: >-
            HTTP error response representation with security-conscious design.


            This struct contains all the information needed to serialize an
            error

            response, including the error name, message, HTTP status code,
            resource

            information, and user-friendly messages.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: >-
            HTTP error response representation with security-conscious design.


            This struct contains all the information needed to serialize an
            error

            response, including the error name, message, HTTP status code,
            resource

            information, and user-friendly messages.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - BearerAuth: []
components:
  schemas:
    Pipeline:
      description: Pipeline response.
      type: object
      properties:
        createdAt:
          description: Timestamp when the pipeline was created.
          type: string
          format: date-time
        createdBy:
          description: Account that created this pipeline.
          allOf:
            - $ref: '#/components/schemas/AccountRef'
        definition:
          description: Detection + redaction configuration.
          allOf:
            - $ref: '#/components/schemas/PipelineDefinition'
        description:
          description: Pipeline description.
          type: string
        displayName:
          description: Pipeline display name.
          type: string
        retention:
          $ref: '#/components/schemas/RetentionOverride'
          description: Per-scope data-retention override, when the pipeline sets one.
        slug:
          description: URL slug of the pipeline, unique within its workspace.
          allOf:
            - $ref: '#/components/schemas/Handle'
        status:
          description: Pipeline lifecycle status.
          allOf:
            - $ref: '#/components/schemas/PipelineStatus'
        updatedAt:
          description: Timestamp when the pipeline was last updated.
          type: string
          format: date-time
        workspaceSlug:
          description: Handle of the workspace this pipeline belongs to.
          allOf:
            - $ref: '#/components/schemas/Handle'
      required:
        - slug
        - workspaceSlug
        - createdBy
        - displayName
        - status
        - definition
        - createdAt
        - updatedAt
    ErrorResponse:
      description: |-
        HTTP error response representation with security-conscious design.

        This struct contains all the information needed to serialize an error
        response, including the error name, message, HTTP status code, resource
        information, and user-friendly messages.
      type: object
      properties:
        message:
          description: User-friendly error message safe for client display
          type: string
        name:
          description: The error name/type identifier
          type: string
        resource:
          description: The resource that the error relates to (optional, set by handler)
          type: string
        suggestion:
          description: Helpful suggestion for resolving the error (optional)
          type: string
        validation:
          description: Validation error details for field-specific errors
          type: array
          items:
            $ref: '#/components/schemas/ValidationErrorDetail'
      required:
        - name
        - message
    AccountRef:
      description: >-
        Public reference to the account behind a resource — whoever created it,

        uploaded it, triggered it, or performed it.


        Reused across resource responses so an account is always presented the
        same

        way: a handle plus an optional avatar.
      type: object
      properties:
        avatarUrl:
          description: Serve path of the account's avatar, when set.
          type: string
        displayName:
          description: Human-readable display name, when set.
          type: string
        username:
          description: Handle of the account.
          allOf:
            - $ref: '#/components/schemas/Handle'
      required:
        - username
    PipelineDefinition:
      description: >-
        A pipeline's detection + governance intent.


        Holds what a pipeline author decides — the default scope and the
        policies to

        apply. Recognition is entirely server-wide: the built-in pattern set
        plus the

        deployment's NER/LLM lineups and enrichment backends live in the engine

        config, not here. Stored as JSON in the pipeline's `definition` column
        but

        validated against this schema at the API boundary.


        The label catalog is not part of this: the policies own the label
        vocabulary,

        and the engine derives the detection catalog from them at run time.


        The split:


        - `default_scope` — optional pipeline-wide scope a document may
        override.

        - `policy_slugs` — references to the workspace's policies, resolved at
        run
          time.
      type: object
      properties:
        defaultScope:
          $ref: '#/components/schemas/ScopeParams'
          description: >-
            Optional pipeline-wide scope (languages, jurisdictions, document
            labels).


            A document's own scope overrides this at detect time; absent here
            means

            the document must assert its own.
        policySlugs:
          description: >-
            Slugs of workspace policies applied at redaction.


            Stored relationally in the `workspace_pipeline_policies` join table,
            not the JSON

            definition; surfaced here so the API exposes one coherent object.
          type: array
          items:
            $ref: '#/components/schemas/Handle'
          maxItems: 64
      additionalProperties: false
    RetentionOverride:
      description: >-
        A pipeline's optional per-scope override of the workspace retention. A
        `None`

        field inherits the workspace value for that scope.


        Only scopes a pipeline actually produces are overridable — original
        documents

        are ingested, not produced by a pipeline, so they have no per-pipeline

        override and always follow the workspace baseline.
      type: object
      properties:
        auditLogs:
          $ref: '#/components/schemas/Retention'
          description: Overrides audit-blob retention when set.
          default: null
        redactedDocuments:
          $ref: '#/components/schemas/Retention'
          description: Overrides redacted-document retention when set.
          default: null
    Handle:
      description: >-
        Lowercase, dash-separated identifier used in URLs and as account
        handles.
      type: string
      maxLength: 32
      minLength: 3
      pattern: ^[a-z0-9]+(?:-[a-z0-9]+)*$
    PipelineStatus:
      description: >-
        Defines the lifecycle status of a pipeline definition.


        This enumeration corresponds to the `PIPELINE_STATUS` PostgreSQL enum
        and is used

        to track whether a pipeline is being configured, enabled and ready to
        run, or disabled.
      oneOf:
        - description: Pipeline is being configured
          type: string
          const: draft
        - description: Pipeline is ready to run
          type: string
          const: enabled
        - description: Pipeline is disabled
          type: string
          const: disabled
    ValidationErrorDetail:
      description: Validation error details for field-specific errors.
      type: object
      properties:
        code:
          description: Error code for the validation failure
          type: string
        field:
          description: Field name that failed validation
          type: string
        message:
          description: Human-readable error message
          type: string
        params:
          description: Additional parameters related to the validation error
          type: object
          additionalProperties: true
      required:
        - field
        - code
        - message
    ScopeParams:
      description: |-
        Caller-asserted scope for one request.

        A narrower wire projection of `elide::recognition::Scope`:
        `languages` and `countries` (typed, elide-native), plus
        elide's [`ScopeMetadata`] block for free-form classification
        strings (`tags`, `purpose`, `audience`). The engine assembles
        this plus a server-minted `correlation_id` and a policy-derived
        label catalog into the orchestrator's `Scope` at compile time.
      type: object
      properties:
        countries:
          description: |-
            Caller-asserted jurisdictions.

            When non-empty, recognizers that carry per-rule country
            scopes skip rules that match none of them. An empty list
            means "any": rules that declare countries still run as a
            permissive fallback so callers who don't assert a
            jurisdiction don't lose detections.
          type: array
          items:
            $ref: '#/components/schemas/CountryCode'
        languages:
          description: |-
            Caller-asserted languages for the analysis.

            Empty means the caller asserted none, leaving detection
            (if a language enricher runs) to fill in.
          allOf:
            - $ref: '#/components/schemas/Languages'
          default: []
        metadata:
          description: |-
            Free-form request context: document tags, request purpose,
            output audience. See elide's [`ScopeMetadata`].
          allOf:
            - $ref: '#/components/schemas/ScopeMetadata'
    Retention:
      description: |-
        How long a class of data is retained.

        Wire shape is internally tagged on `mode`: `{ "mode": "forever" }`,
        `{ "mode": "zeroDays" }`, `{ "mode": "days", "days": 30 }`.
      oneOf:
        - description: Keep data indefinitely (the default).
          type: object
          properties:
            mode:
              type: string
              const: forever
          required:
            - mode
        - description: Delete data as soon as it has been processed.
          type: object
          properties:
            mode:
              type: string
              const: zeroDays
          required:
            - mode
        - description: Keep data for a fixed number of days, then delete it.
          type: object
          properties:
            days:
              description: Number of days to retain data.
              type: integer
              format: uint32
              minimum: 0
            mode:
              type: string
              const: days
          required:
            - mode
            - days
    CountryCode:
      description: |-
        [ISO 3166-1] country, identified by its code.

        Wraps [`celes::Country`], a static table entry carrying the numeric,
        alpha-2, and alpha-3 codes together with the country's name. Because
        every value comes from that fixed table, a `CountryCode` is always a
        real, recognised country; there is no way to hold an invalid one.

        Used to scope region-sensitive recognizers (a phone-number or
        national-id pattern, say) to the country whose format they target.

        Serializes as its alpha-2 code (e.g. `"US"`).

        [ISO 3166-1]: https://www.iso.org/iso-3166-country-codes.html
      type: string
    Languages:
      description: |-
        List of [`Language`]s resolved for one text scan.

        Built by a detector (one entry per detected region) or by the caller
        asserting languages. Carried on a [`RecognizerContext`] so every
        recognizer and the context enhancer can consult the call's languages.

        [`RecognizerContext`]: crate::recognition::RecognizerContext
      type: array
      items:
        $ref: '#/components/schemas/Language'
    ScopeMetadata:
      description: >-
        Caller-asserted scope shared across every payload of one analysis.


        Built once with the `with_*` chain and passed by reference to the

        analyzer, which borrows it into a fresh [`RecognizerContext`] per

        payload. It holds only what the *caller* asserts about the analysis as a

        whole — languages, jurisdictions, document labels, the target catalog, a

        correlation id — none of which depends on the medium, so one [`Scope`]

        drives a text, image, or audio analysis alike.


        Per-medium regions (caller-supplied inclusions and exclusions, which are

        `M::Location`-typed) live in [`Annotations`], attached to the analyzer

        of that modality. The per-payload working state (NLP artifacts, detected

        languages) lives on the context, not here.


        [`RecognizerContext`]: super::RecognizerContext

        [`Annotations`]: super::annotation::Annotations

        Free-form, caller-asserted request context: the *document* it is about
        and

        the *request* driving it.


        Three axes of opaque classification strings elide neither ships nor

        interprets — a downstream policy layer chooses what `"medical"` or

        `"fraud_detection"` or `"auditor"` mean. They are read in two places: a

        recognizer may bias its detection on them (the LLM prompt lists them so
        the

        model attends to the right terms), and a scope-aware operator predicate
        may

        branch on them at selection time (redact the same document differently
        per

        [`audience`]).


        - [`tags`] classify the *document* (`"medical"`, `"gdpr-request"`).

        - [`purpose`] is why the request exists (`"fraud_detection"`).

        - [`audience`] is who the redacted output is for (`"support_agent"`,
          `"auditor"`) — the axis PCI-style "same document, two masks" branches on.

        [`tags`]: Self::tags

        [`purpose`]: Self::purpose

        [`audience`]: Self::audience
      type: object
      properties:
        audience:
          description: >-
            Who the redacted output is for (e.g. `"support_agent"`,
            `"auditor"`).

            The axis a per-audience redaction branches on: one detected
            document,

            selected differently per audience. May hold several.
          type: array
          default: []
          items:
            type: string
        purpose:
          description: >-
            The caller-asserted business purpose driving this request (e.g.

            `"fraud_detection"`, `"gdpr_erasure_request"`). A scope-aware
            operator

            predicate may skip or swap a rule based on it; a recognizer may bias

            detection on it. `None` when the caller asserts no purpose.
          type: string
          default: null
        tags:
          description: |-
            Document-level classification tags (e.g. `"medical"`,
            `"gdpr-request"`). Recognizers may use these to bias their behavior
            for domain-specific terms; those that don't ignore the field.

            Named `tags`, not `labels`, to keep "label" reserved for the entity
            taxonomy ([`LabelRef`]/[`LabelCatalog`]): these classify the
            *document*, whereas the scope's catalog names the entity *types* to
            emit.

            [`LabelRef`]: crate::entity::LabelRef
            [`LabelCatalog`]: crate::entity::LabelCatalog
          type: array
          default: []
          items:
            type: string
    Language:
      description: |-
        Single language detection result.

        Carries the language plus an optional confidence and an optional
        byte-offset [`LanguageSpan`]. Backends that don't expose confidence
        leave it `None`; single-language detectors that don't track per-region
        information leave `span` as `None`. The `provenance` field records
        whether the answer came from a detector or was asserted by the caller.
      type: object
      properties:
        confidence:
          $ref: '#/components/schemas/Confidence'
          description: Optional confidence score. `None` when not exposed.
        language:
          description: Language.
          allOf:
            - $ref: '#/components/schemas/LanguageTag'
        provenance:
          description: 'How this language was obtained: detected or caller-asserted.'
          allOf:
            - $ref: '#/components/schemas/LanguageProvenance'
        span:
          $ref: '#/components/schemas/LanguageSpan'
          description: |-
            Byte-offset range this detection applies to, when known. `None`
            means the whole text.
      required:
        - language
        - provenance
    Confidence:
      description: |-
        Confidence score in the closed range `0.0..=1.0`.

        Carried by every provenance [`AuditEvent`] (the `before`/`after` of a
        recognition, fusion, or calibration) and by the effective confidence
        of an [`Entity`]. The newtype enforces the range at construction so
        no downstream code has to defend against values outside `[0, 1]`.

        Distinct from [`ConfidenceThreshold`] so the two cannot be confused
        at a call site: a score is *produced* by detection, a threshold is a
        *cutoff* configured to filter scores. Compare the two with
        [`ConfidenceThreshold::passes`].

        [`AuditEvent`]: crate::entity::audit::AuditEvent
        [`Entity`]: crate::entity::Entity
      type: number
      format: float
    LanguageTag:
      description: |-
        Well-formed [BCP 47] language tag, such as `en`, `en-US`, or
        `zh-Hant-HK`.

        Wraps [`oxilangtag::LanguageTag`] over a [`HipStr`] backing store, so
        short tags (the overwhelming common case) stay inline without a heap
        allocation. Parsing validates the tag's structure up front; the
        newtype therefore guarantees that any `LanguageTag` value in the
        model is syntactically valid.

        Used to record the language a recognizer is scoped to, or the
        detected language of a span of content.

        [BCP 47]: https://www.rfc-editor.org/info/bcp47
      type: string
    LanguageProvenance:
      description: |-
        How a [`Language`]'s language was obtained.

        Lets consumers distinguish "a detector ran and got this answer" from
        "the caller asserted this language". An assertion may still carry an
        optional confidence, so this is independent of the confidence field.
      oneOf:
        - description: Produced by a language-detection backend.
          type: string
          const: detected
        - description: Asserted by the caller.
          type: string
          const: asserted
    LanguageSpan:
      description: |-
        Byte-offset range within the analyzed text.

        Attached to a [`Language`] when the detector knows the span
        its answer covers (mixed-language input produces multiple detections,
        each with a distinct span). Single-language detections from
        non-segmenting backends, and caller-asserted answers, typically leave
        the span as `None`.
      type: object
      properties:
        end:
          description: Byte offset of the span end in the original text.
          type: integer
          format: uint
          minimum: 0
        start:
          description: Byte offset of the span start in the original text.
          type: integer
          format: uint
          minimum: 0
      required:
        - start
        - end

````