Skip to content

Commit

Permalink
Adds docs links to bindings bits
Browse files Browse the repository at this point in the history
This adds a bindings section to the docs which has links to both the
Ruby and Python bindings, the core bindings, and the REST api browsable
docs for both too.

https://pulp.plan.io/issues/4844
closes #4844
  • Loading branch information
Brian Bouterse committed May 29, 2019
1 parent 418d2d4 commit 8f65ae0
Show file tree
Hide file tree
Showing 3 changed files with 55 additions and 1 deletion.
53 changes: 53 additions & 0 deletions docs/bindings.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
Client Bindings
===============

Python Client
-------------

The `pulp-ansible-client package <https://pypi.org/project/pulp-ansible-client/>`_ on PyPI provides
bindings for all API calls in the `pulp_ansible API documentation <../restapi.html>`_. It is
currently published daily and with every RC.

The `pulpcore-client package <https://pypi.org/project/pulpcore-client/>`_ on PyPI provides bindings
for all API calls in the `pulpcore API documentation <https://docs.pulpproject.org/en/3.0/nightly/
restapi.html>`_. It is currently published daily and with every RC.


Ruby Client
-----------

The `pulp_ansible_client Ruby Gem <https://rubygems.org/gems/pulp_ansible_client>`_ on rubygems.org
provides bindings for all API calls in the `pulp_ansible API documentation <../restapi.html>`_. It
is currently published daily and with every RC.

The `pulpcore_client Ruby Gem <https://rubygems.org/gems/pulpcore_client>`_ on rubygems.org provides
bindings for all API calls in the `pulpcore API documentation <https://docs.pulpproject.org/en/3.0/
nightly/restapi.html>`_. It is currently published daily and with every RC.


Client in a language of your choice
-----------------------------------

A client can be generated using Pulp's OpenAPI schema and any of the available `generators
<https://openapi-generator.tech/docs/generators.html>`_.

Generating a client is a two step process:

**1) Download the OpenAPI schema for pulpcore and all installed plugins:**

.. code-block:: bash
curl -o api.json http://<pulp-hostname>:24817/pulp/api/v3/docs/api.json
The OpenAPI schema for a specific plugin can be downloaded by specifying the plugin's module name
as a GET parameter. For example for ``pulp_ansible`` only endpoints use a query like this:

.. code-block:: bash
curl -o api.json http://<pulp-hostname>:24817/pulp/api/v3/docs/api.json?plugin=pulp_ansible
**2) Generate a client using openapi-generator.**

The schema can then be used as input to the openapi-generator-cli. The documentation on getting
started with openapi-generator-cli is available on
`openapi-generator.tech <https://openapi-generator.tech/#try>`_.
3 changes: 2 additions & 1 deletion docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ Table of Contents

installation
workflows/index
restapi/index
restapi
bindings


Indices and tables
Expand Down
File renamed without changes.

0 comments on commit 8f65ae0

Please sign in to comment.