Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[0.16] change API_KEY examples to avoid ansible issues #2211

Merged
merged 1 commit into from
Dec 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ API operations that support Filter Query provide an HTTP request parameter named
To use the Filter Query with an operation that returns a [Run](/docs/concepts/core-concepts/#run) data can be done as follows.

```bash
curl -s 'http://localhost:8080/api/sql/1/queryrun?query=$.*&array=true' -H 'content-type: application/json' -H 'X-Horreum-API-Key: '$API_KEY
curl -s 'http://localhost:8080/api/sql/1/queryrun?query=$.*&array=true' -H 'content-type: application/json' -H "X-Horreum-API-Key: $API_KEY"
{
"valid": true,
"jsonpath": "$.*",
Expand All @@ -29,7 +29,7 @@ The response contains an enclosing JSON object that is common for Filter Query o
To filter the above API operation to retrieve only the *results* property of the uploaded [Run](/docs/concepts/core-concepts/#run) object the *query* parameter is defined as `$.results`

```bash
curl -s 'http://localhost:8080/api/sql/1/queryrun?query=$.results&array=true' -H 'content-type: application/json' -H 'X-Horreum-API-Key: '$API_KEY
curl -s 'http://localhost:8080/api/sql/1/queryrun?query=$.results&array=true' -H 'content-type: application/json' -H "X-Horreum-API-Key: $API_KEY"
{
"valid": true,
"jsonpath": "$.results",
Expand Down
8 changes: 4 additions & 4 deletions docs/site/content/en/docs/Tasks/import-export/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ Click on Schema/Test and there is a button where you can select either _Import S
```bash
curl 'http://localhost:8080/api/schema/import/' \
-s -X POST -H 'content-type: application/json' \
-H 'X-Horreum-API-Key: '$API_KEY \
-H "X-Horreum-API-Key: $API_KEY" \
-d @/path/to/schema.json
```

Expand All @@ -55,7 +55,7 @@ If you are unfamiliar with generating an API Key, please see [Upload Run](/docs/
```bash
curl 'http://localhost:8080/api/test/import/' \
-s -X POST -H 'content-type: application/json' \
-H 'X-Horreum-API-Key: '$API_KEY \
-H "X-Horreum-API-Key: $API_KEY" \
-d @/path/to/test.json
```

Expand All @@ -64,7 +64,7 @@ curl 'http://localhost:8080/api/test/import/' \
```bash
SCHEMAID='123'
curl 'http://localhost:8080/api/schema/export/?id='$SCHEMAID \
-H 'X-Horreum-API-Key: '$API_KEY \
-H "X-Horreum-API-Key: $API_KEY" \
-O --output-dir /path/to/folder
```

Expand All @@ -74,6 +74,6 @@ curl 'http://localhost:8080/api/schema/export/?id='$SCHEMAID \
TESTID='123'
curl 'http://localhost:8080/api/test/export/?id=$TESTID' \
-s -X POST -H 'content-type: application/json' \
-H 'X-Horreum-API-Key: '$API_KEY \
-H "X-Horreum-API-Key: $API_KEY" \
-O --output-dir /path/to/folder
```
2 changes: 1 addition & 1 deletion docs/site/content/en/docs/Tasks/manage-reports/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,5 @@ The same task can be repeated using the web API to delete a `Report`. Copy and p

```bash
REPORT_ID=<your_report_id_here>
curl 'http://localhost:8080/api/report/table/'$REPORT_ID -H 'content-type: application/json' -H 'X-Horreum-API-Key: '$API_KEY --request DELETE -v
curl 'http://localhost:8080/api/report/table/'$REPORT_ID -H 'content-type: application/json' -H "X-Horreum-API-Key: $API_KEY" --request DELETE -v
```
2 changes: 1 addition & 1 deletion docs/site/content/en/docs/Tasks/upload-run/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ OWNER='dev-team'
ACCESS='PUBLIC'
curl 'http://localhost:8080/api/run/data?test='$TEST'&start='$START'&stop='$STOP'&owner='$OWNER'&access='$ACCESS \
-s -X POST -H 'content-type: application/json' \
-H 'X-Horreum-API-Key: '$API_KEY \
-H "X-Horreum-API-Key: $API_KEY" \
-d @/path/to/data.json
```

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ STOP='2021-08-01T10:40:28.00Z'
OWNER='dev-team'
ACCESS='PUBLIC'
curl 'http://localhost:8080/api/run/data?test='$TEST'&start='$START'&stop='$STOP'&owner='$OWNER'&access='$ACCESS \
-s -H 'content-type: application/json' -H 'X-Horreum-API-Key: '$API_KEY \
-s -H 'content-type: application/json' -H "X-Horreum-API-Key: $API_KEY" \
-d @/tmp/run.json
```

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ The query can be executed by making a call to the Horreum API;

```bash
$ curl 'http://localhost:8080/api/run/data?test='$TEST'&start='$START'&stop='$STOP'&owner='$OWNER'&access='$ACCESS \
-s -H 'content-type: application/json' -H 'X-Horreum-API-Key: '$API_KEY \
-s -H 'content-type: application/json' -H "X-Horreum-API-Key: $API_KEY" \
-d @/tmp/collector_query.json
```

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ The document query can then be sumitted to the Horreum API;

```bash
$ curl 'http://localhost:8080/api/run/data?test='$TEST'&start='$START'&stop='$STOP'&owner='$OWNER'&access='$ACCESS \
-s -H 'content-type: application/json' -H 'X-Horreum-API-Key: '$API_KEY \
-s -H 'content-type: application/json' -H "X-Horreum-API-Key: $API_KEY" \
-d @/tmp/elastic_payload.json
```

Expand Down Expand Up @@ -101,7 +101,7 @@ The query can be executed by making a call to the Horreum API;

```bash
$ curl 'http://localhost:8080/api/run/data?test='$TEST'&start='$START'&stop='$STOP'&owner='$OWNER'&access='$ACCESS \
-s -H 'content-type: application/json' -H 'X-Horreum-API-Key: '$API_KEY \
-s -H 'content-type: application/json' -H "X-Horreum-API-Key: $API_KEY" \
-d @/tmp/elastic_query.json
```

Expand Down
Loading