Skip to content

Sonatype Nexus 3 command line using REST interface

Notifications You must be signed in to change notification settings

vbauchart/nexuscli

Repository files navigation

swagger-client

No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)

This Python package is automatically generated by the Swagger Codegen project:

  • API version: 3.7.0-04
  • Package version: 1.0.0
  • Build package: io.swagger.codegen.languages.PythonClientCodegen

Requirements.

Python 2.7 and 3.4+

Installation & Usage

pip install

If the python package is hosted on Github, you can install directly from Github

pip install git+https://github.com//.git

(you may need to run pip with root permission: sudo pip install git+https://github.com//.git)

Then import the package:

import nexuscli 

Setuptools

Install via Setuptools.

python setup.py install --user

(or sudo python setup.py install to install the package for all users)

Then import the package:

import nexuscli

Getting Started

Please follow the installation procedure and then run the following:

from __future__ import print_function
import time
import nexuscli
from nexuscli.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: basicAuth
nexuscli.configuration.username = 'YOUR_USERNAME'
nexuscli.configuration.password = 'YOUR_PASSWORD'
# create an instance of the API class
api_instance = nexuscli.AssetsApi()
id = 'id_example' # str | Id of the asset to delete

try:
    # Delete a single asset
    api_instance.delete_asset(id)
except ApiException as e:
    print("Exception when calling AssetsApi->delete_asset: %s\n" % e)

Documentation for API Endpoints

All URIs are relative to https://localhost/service/siesta/

Class Method HTTP request Description
AssetsApi delete_asset DELETE /rest/beta/assets/{id} Delete a single asset
AssetsApi get_asset_by_id GET /rest/beta/assets/{id} Get a single asset
AssetsApi get_assets GET /rest/beta/assets List assets
ComponentsApi delete_component DELETE /rest/beta/components/{id} Delete a single component
ComponentsApi get_component_by_id GET /rest/beta/components/{id} Get a single component
ComponentsApi get_components GET /rest/beta/components List components
ReadonlyApi force_release POST /rest/beta/read-only/force-release Forcibly release read-only
ReadonlyApi freeze POST /rest/beta/read-only/freeze Enable read-only
ReadonlyApi get GET /rest/beta/read-only Get read-only state
ReadonlyApi release POST /rest/beta/read-only/release Release read-only
ScriptApi add POST /rest/v1/script Add a new script
ScriptApi browse GET /rest/v1/script List all stored scripts
ScriptApi delete DELETE /rest/v1/script/{name} Delete stored script by name
ScriptApi edit PUT /rest/v1/script/{name} Update stored script by name
ScriptApi read GET /rest/v1/script/{name} Read stored script by name
ScriptApi run1 POST /rest/v1/script/{name}/run Run stored script by name
SearchApi search GET /rest/beta/search Search components
SearchApi search_and_download_assets GET /rest/beta/search/assets/download Search and download asset
SearchApi search_assets GET /rest/beta/search/assets Search assets
TasksApi get_task_by_id GET /rest/beta/tasks/{id} Get a single task by id
TasksApi get_tasks GET /rest/beta/tasks List tasks
TasksApi run POST /rest/beta/tasks/{id}/run Run task
TasksApi stop POST /rest/beta/tasks/{id}/stop Stop task

Documentation For Models

Documentation For Authorization

basicAuth

  • Type: HTTP basic authentication

Author

About

Sonatype Nexus 3 command line using REST interface

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published