Pritunl API Shell - a Curl wrapper for secure and simplified command-line requests
./pritunl-api-shell <method> <path> [payload]
./pritunl-api-shell GET /entity-uri
./pritunl-api-shell POST /entity-uri '{"name":"New Entity"}'
./pritunl-api-shell PUT /entity-uri '{"name":"Update Entity"}'
./pritunl-api-shell DELETE /entity-uri
- Replace
<method>
with the desired HTTP method (GET
,POST
,PUT
,DELETE
, etc.) - Replace
<path>
with the Pritunl API endpoint path - Replace
[payload]
with the optional request payload in JSON format
- Make the script executable:
chmod +x pritunl-api-shell
- Place the script in your preferred location, such as
~/bin
or/usr/local/bin
- Set the
PRITUNL_API_TOKEN
,PRITUNL_API_SECRET
, andPRITUNL_BASE_URL
environment variables to authenticate with the Pritunl API
- For Postman Users
- For a seamless API authentication experience, check out the Pritunl API Authentication (for Postman Pre-Request Script) script. This Postman pre-request script generates the necessary authentication headers for Pritunl API requests. Simply import the script into your Postman collection and enjoy effortless authentication!