Metadata-Version: 2.0
Name: httpie-nsof
Version: 1.5
Summary: Nsof OAuth 2 plugin for HTTPie.
Home-page: https://github.com/nsofnetworks/httpie-nsof
Author: Alon Horowitz
Author-email: alon@nsof.io
License: Apache License 2.0
Download-URL: https://github.com/nsofnetworks/httpie-nsof/archive/1.5.tar.gz
Description-Content-Type: UNKNOWN
Keywords: httpie oauth oauth2 nsof token
Platform: UNKNOWN
Classifier: Development Status :: 5 - Production/Stable
Classifier: Programming Language :: Python
Classifier: Environment :: Plugins
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Topic :: Internet :: WWW/HTTP
Classifier: Topic :: Utilities
Requires-Dist: httpie (>=0.7.0)
Requires-Dist: pyjwt (>=1.4.2)

===========
httpie-nsof
===========

Nsof OAuth 2 plugin for the `HTTPie <https://github.com/jkbr/httpie>`_ command line HTTP client.


Installation
------------

.. code-block:: bash

    $ pip install httpie-nsof


You should now see ``nsof`` under ``--auth-type`` in ``$ http --help`` output.


Setup
-----

.. code-block:: bash

    $ httpie-nsof-setup


Configure Nsof's auth plugin with your creds (saved in ~/.httpie/config.json).
The credentials can be either a username/password or API Key ID/API Key Secret

Notes:
    - if username is not provided in conf file it will be searched at HTTPIE_NSOF_USERNAME
    - if password is not provided in conf file it will be searched at HTTPIE_NSOF_PASSWORD
    - manually inputted username/password supersede conf file and environment variables


Usage
-----

.. code-block:: bash

    $ http --auth-type=nsof GET https://api.nsof.io/v1/users


It's possible to pass a different effective org using the env ``EORG``:

.. code-block:: bash

    $ EORG=nsof http --auth-type=nsof GET https://api.nsof.io/v1/users

