Labels ·
operationId:ListLabels
List Labels
GET
/v1/functions/{functionId}/labels
Description
List labels
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
functionId |
string |
yes | — |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
startIndex |
integer (int32) |
no | The zero-based index of the first result to return |
count |
integer (int32) |
no | The number of results to return |
Responses
| Status | Description | Body |
|---|---|---|
200 |
Success | array<Label> |
Code samples
curl
curl -X GET \
-H 'Authorization: Bearer <accessToken>' \
'https://www.nyckel.com/v1/functions/<functionId>/labels'
Python
import requests
url = 'https://www.nyckel.com/v1/functions/<functionId>/labels'
headers = {
'Authorization': 'Bearer <accessToken>',
}
response = requests.get(url, headers=headers)
print(response.json())
JavaScript
fetch('https://www.nyckel.com/v1/functions/<functionId>/labels', {
method: 'GET',
headers: {
'Authorization': 'Bearer <accessToken>',
},
})
.then(response => response.json())
.then(data => console.log(data));
PHP
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'https://www.nyckel.com/v1/functions/<functionId>/labels');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
$headers = array(
'Authorization: Bearer <accessToken>',
);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
Related
Source of truth: /openapi/v1.json