Skip to content

Commit

Permalink
Use https for requests (#8971)
Browse files Browse the repository at this point in the history
`https` is used more commonly because most users will use the security plugin.

Signed-off-by: Naarcha-AWS <97990722+Naarcha-AWS@users.noreply.github.com>
(cherry picked from commit ff5fc79)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
  • Loading branch information
github-actions[bot] committed Dec 18, 2024
1 parent 3c01cb1 commit b2b7468
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions _getting-started/communicate.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ The default username is `admin`, and the password is set in your `docker-compose
OpenSearch generally returns responses in a flat JSON format by default. For a human-readable response body, provide the `pretty` query parameter:

```bash
curl -X GET "http://localhost:9200/_cluster/health?pretty"
curl -X GET "https://localhost:9200/_cluster/health?pretty"
```
{% include copy.html %}

Expand All @@ -46,7 +46,7 @@ For more information about `pretty` and other useful query parameters, see [Comm
For requests that contain a body, specify the `Content-Type` header and provide the request payload in the `-d` (data) option:

```json
curl -X GET "http://localhost:9200/students/_search?pretty" -H 'Content-Type: application/json' -d'
curl -X GET "https://localhost:9200/students/_search?pretty" -H 'Content-Type: application/json' -d'
{
"query": {
"match_all": {}
Expand All @@ -59,7 +59,7 @@ curl -X GET "http://localhost:9200/students/_search?pretty" -H 'Content-Type: ap

The Dev Tools console in OpenSearch Dashboards uses a simpler syntax to format REST requests as compared to the cURL command. To send requests in Dev Tools, use the following steps:

1. Access OpenSearch Dashboards by opening `http://localhost:5601/` in a web browser on the same host that is running your OpenSearch cluster. The default username is `admin`, and the password is set in your `docker-compose.yml` file in the `OPENSEARCH_INITIAL_ADMIN_PASSWORD=<custom-admin-password>` setting.
1. Access OpenSearch Dashboards by opening `https://localhost:5601/` in a web browser on the same host that is running your OpenSearch cluster. The default username is `admin`, and the password is set in your `docker-compose.yml` file in the `OPENSEARCH_INITIAL_ADMIN_PASSWORD=<custom-admin-password>` setting.
1. On the top menu bar, go to **Management > Dev Tools**.
1. In the left pane of the console, enter the following request:
```json
Expand Down

0 comments on commit b2b7468

Please sign in to comment.