Sonatype Nexus Repository Script API

The Script API from Sonatype Nexus Repository — 3 operation(s) for script.

Operations 6

GET /v1/script List all stored scripts #
POST /v1/script Add a new script #
GET /v1/script/{name} Read stored script by name #
PUT /v1/script/{name} Update stored script by name #
DELETE /v1/script/{name} Delete stored script by name #
POST /v1/script/{name}/run Run stored script by name #

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/nexus:nexus-script-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

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

nexus-script-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Nexus Repository Manager REST Script API
  version: 3.97.2-02
servers:
- url: /service/rest
tags:
- name: Script
paths:
  /v1/script:
    get:
      tags:
      - Script
      summary: List all stored scripts
      operationId: listScript
      responses:
        '200':
          description: Stored scripts returned
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/ScriptXO'
    post:
      tags:
      - Script
      summary: Add a new script
      operationId: createScript
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ScriptXO'
        required: true
      responses:
        '204':
          description: Script was added
        '410':
          description: Script creation is disabled
  /v1/script/{name}:
    get:
      tags:
      - Script
      summary: Read stored script by name
      operationId: getScript
      parameters:
      - name: name
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Script returned
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ScriptXO'
        '404':
          description: No script with the specified name
    put:
      tags:
      - Script
      summary: Update stored script by name
      operationId: updateScript
      parameters:
      - name: name
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ScriptXO'
        required: true
      responses:
        '204':
          description: Script was updated
        '404':
          description: No script with the specified name
        '410':
          description: Script updating is disabled
    delete:
      tags:
      - Script
      summary: Delete stored script by name
      operationId: deleteScript
      parameters:
      - name: name
        in: path
        required: true
        schema:
          type: string
      responses:
        '204':
          description: Script was deleted
        '404':
          description: No script with the specified name
  /v1/script/{name}/run:
    post:
      tags:
      - Script
      summary: Run stored script by name
      operationId: createScriptRun
      parameters:
      - name: name
        in: path
        required: true
        schema:
          type: string
      requestBody:
        content:
          text/plain:
            schema:
              type: string
          application/json:
            schema:
              type: string
      responses:
        '200':
          description: Script executed successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ScriptResultXO'
        '404':
          description: No script with the specified name
        '410':
          description: Script execution is disabled
        '500':
          description: Script execution failed with exception
components:
  schemas:
    ScriptXO:
      required:
      - content
      - name
      - type
      type: object
      properties:
        name:
          minLength: 1
          pattern: ^[a-zA-Z0-9\-]{1}[a-zA-Z0-9_\-\.]*$
          type: string
        content:
          minLength: 1
          type: string
        type:
          minLength: 1
          type: string
    ScriptResultXO:
      required:
      - name
      type: object
      properties:
        name:
          minLength: 1
          type: string
        result:
          type: string