Skip to content

Commit

Permalink
Add basic documentation for API paths in README
Browse files Browse the repository at this point in the history
  • Loading branch information
raincz authored and dhollinger committed Mar 2, 2024
1 parent 147bceb commit f3acb40
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -214,3 +214,27 @@ Default: `true`
Type: bool
Description: Run `puppet generate types` after updating an environment
Default: `true`

## Usage

Webhook API provides following paths

### GET /health

Get health assessment about the Webhook API server

### GET /api/v1/queue

Get current queue status of the Webhook API server

### POST /api/v1/r10k/environment

Updates a given puppet environment, ie. `r10k deploy environment`. This only updates a specific environment governed by the branch name.

### POST /api/v1/r10k/module

Updates a puppet module, ie. `r10k deploy module`. The default behaviour of r10k is to update the module in all environments that have it. Module name defaults to the git repository name.

Available URL arguments (`?argument=value`):
* branch_only - If set, this will only update the module in an environment set by the branch, as opposed to all environments. This is equivalent to the `--environment` r10k option.
* module_name - Sometimes git repository and module name cannot have the same name due to arbitrary naming restrictions. This option forces the module name to be the given value instead of repository name.

0 comments on commit f3acb40

Please sign in to comment.