## Documentation Index

Fetch the complete documentation index at: [/docs/llms.txt](/content/docs/llms.txt)

Use this file to discover all available pages before exploring further.

Get

### cURL

```
curl --request GET \
  --url https://management.stytch.com/pwa/v3/projects/:project_slug/environments/:environment_slug/event_log_streaming/:destination_type \
  --header 'Authorization: Basic <encoded-value>'
```

### Python

```
import requests

url = "https://management.stytch.com/pwa/v3/projects/:project_slug/environments/:environment_slug/event_log_streaming/:destination_type"

headers = {"Authorization": "Basic <encoded-value>"}

response = requests.get(url, headers=headers)

print(response.text)
```

### JavaScript (Fetch)

```
const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};

fetch('https://management.stytch.com/pwa/v3/projects/:project_slug/environments/:environment_slug/event_log_streaming/:destination_type', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
```

### PHP

```
<?php

$curl = curl_init();

curl_setopt_array($curl, [\
  CURLOPT_URL => "https://management.stytch.com/pwa/v3/projects/:project_slug/environments/:environment_slug/event_log_streaming/:destination_type",\
  CURLOPT_RETURNTRANSFER => true,\
  CURLOPT_ENCODING => "",\
  CURLOPT_MAXREDIRS => 10,\
  CURLOPT_TIMEOUT => 30,\
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,\
  CURLOPT_CUSTOMREQUEST => "GET",\
  CURLOPT_HTTPHEADER => [\
    "Authorization: Basic <encoded-value>"\
  ],\
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
?>
```

### Go

```
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

url := "https://management.stytch.com/pwa/v3/projects/:project_slug/environments/:environment_slug/event_log_streaming/:destination_type"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("Authorization", "Basic <encoded-value>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))
}
```

### Unirest (Java)

```
HttpResponse<String> response = Unirest.get("https://management.stytch.com/pwa/v3/projects/:project_slug/environments/:environment_slug/event_log_streaming/:destination_type")
  .header("Authorization", "Basic <encoded-value>")
  .asString();
```

### Ruby

```
require 'uri'
require 'net/http'

url = URI("https://management.stytch.com/pwa/v3/projects/:project_slug/environments/:environment_slug/event_log_streaming/:destination_type")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'

response = http.request(request)
puts response.read_body
```

### Response Codes

- **200**: Success
- **401**: Unauthorized
- **429**: Too Many Requests
- **500**: Internal Server Error

### Response Structure

#### Success Response
```
{
  "request_id": "<string>",
  "event_log_streaming_config": {
    "destination_type": "DATADOG",
    "destination_config": {
      "datadog": {
        "api_key_last_four": "<string>",
        "site": "US"
      },
      "grafana_loki": {
        "hostname": "<string>",
        "username": "<string>",
        "password_last_four": "<string>"
      }
    },
    "streaming_status": "ACTIVE"
  },
  "status_code": 123
}
```

#### Error Responses

**401 Unauthorized**
```
{
  "status_code": 401,
  "request_id": "request-id-test-b05c992f-ebdc-489d-a754-c7e70ba13141",
  "error_type": "unauthorized_credentials",
  "error_message": "Unauthorized credentials.",
  "error_url": "https://stytch.com/docs/api/errors/401"
}
```

**429 Too Many Requests**
```
{
  "status_code": 429,
  "request_id": "request-id-test-b05c992f-ebdc-489d-a754-c7e70ba13141",
  "error_type": "too_many_requests",
  "error_message": "Too many requests have been made.",
  "error_url": "https://stytch.com/docs/api/errors/429"
}
```

**500 Internal Server Error**
```
{
  "status_code": 500,
  "request_id": "request-id-test-b05c992f-ebdc-489d-a754-c7e70ba13141",
  "error_type": "internal_server_error",
  "error_message": "Oops, something seems to have gone wrong, please reach out to support@stytch.com to let us know what went wrong.",
  "error_url": "https://stytch.com/docs/api/errors/500"
}
```

### Authorizations

Authorization
- **Type**: string  
- **Location**: header  
- **Required**: Yes  
- **Description**: Basic authentication header of the form `Basic <encoded-value>`, where `<encoded-value>` is the base64-encoded string `username:password`.

### Path Parameters

- **project_slug** (string): Required  
- **environment_slug** (string): Required  
- **destination_type** (enum<string>): Required; Available options: `DATADOG`, `GRAFANA_LOKI`

### Response

- **200**: application/json, Successful response, with details about the request.
