Skip to content

Commit

Permalink
reference updates
Browse files Browse the repository at this point in the history
Signed-off-by: Archit Sharma <archit8679@gmail.com>
  • Loading branch information
iArchitSharma committed Mar 7, 2024
1 parent c472757 commit f73025f
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 28 deletions.
28 changes: 1 addition & 27 deletions content/en/cloud/reference/_index.md
Original file line number Diff line number Diff line change
@@ -1,33 +1,7 @@
---
title: Reference
description: Low-level ReST API reference for extending Layer5 Cloud.
description: References for using Layer5 Cloud’s various features and components.
weight: 20
categories: [Reference]
tags: [extensibility]
---
To create integrations, retrieve data, and automate your cloud native infrastructure, build with the Layer5 Cloud REST API.

## Authenticating with the API

In order to authenticate to Layer5 Cloud's REST API, you need to generate and use a [security token](../security/tokens). Visit your [user account's security tokens](https://meshery.layer5.io/security/tokens) and generate a long-lived security token. Security tokens are without expiration date. You can generate as many tokens as you like. You can also revoke them at any time.

To authenticate with the API, pass the token as a bearer token in the `Authorization` header. For example, in cURL:

```bash
curl <protocol>://<Layer5-cloud-hostname>/<API> \
-H "Authorization: Bearer <token>"
```

- Replace `<protocol>` with `http` or `https` depending on your Layer5 Cloud instance.
- Replace `<Layer5-cloud-hostname>` with the hostname or IP address of your hosted Layer5 Cloud instance. For example, [`https://cloud.layer5.io`](https://cloud.layer5.io).
- Replace `<API>` with the API endpoint you want to access. For example, `/api/identity/users/profile`.
- Replace `<token>` with the security token you generated.

## All API Endpoints

{{< alert type="info" >}}
<a href="https://meshery.layer5.io/system/api/docs">Open API Endpoints in new window <i class="fa fa-external-link" aria-hidden="true"></i></a>
{{< /alert >}}



32 changes: 32 additions & 0 deletions content/en/cloud/reference/api-reference.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
title: API Endpoints
description: >
Low-level ReST API reference for extending Layer5 Cloud.
weight: 1
categories: [Reference]
tags: [extensibility]
---

To create integrations, retrieve data, and automate your cloud native infrastructure, build with the Layer5 Cloud REST API.

## Authenticating with the API

In order to authenticate to Layer5 Cloud's REST API, you need to generate and use a [security token](../security/tokens). Visit your [user account's security tokens](https://meshery.layer5.io/security/tokens) and generate a long-lived security token. Security tokens are without expiration date. You can generate as many tokens as you like. You can also revoke them at any time.

To authenticate with the API, pass the token as a bearer token in the `Authorization` header. For example, in cURL:

```bash
curl <protocol>://<Layer5-cloud-hostname>/<API> \
-H "Authorization: Bearer <token>"
```

- Replace `<protocol>` with `http` or `https` depending on your Layer5 Cloud instance.
- Replace `<Layer5-cloud-hostname>` with the hostname or IP address of your hosted Layer5 Cloud instance. For example, [`https://cloud.layer5.io`](https://cloud.layer5.io).
- Replace `<API>` with the API endpoint you want to access. For example, `/api/identity/users/profile`.
- Replace `<token>` with the security token you generated.

## All API Endpoints

{{< alert type="info" >}}
<a href="https://meshery.layer5.io/system/api/docs">Open API Endpoints in new window <i class="fa fa-external-link" aria-hidden="true"></i></a>
{{< /alert >}}
2 changes: 1 addition & 1 deletion content/en/cloud/reference/default-permissions.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: Default Permissions
description: >
List of default permissions granted to the Organizations, Teams and Users roles.
weight: 1
weight: 2
categories: [Identity]
tags: [perms]
---
Expand Down

0 comments on commit f73025f

Please sign in to comment.