Skip to main content
GET
/
v1
/
environment-variables
/
{variableKey}
PHP
declare(strict_types=1);

require 'vendor/autoload.php';

use novu;

$sdk = novu\Novu::builder()
    ->setSecurity(
        'YOUR_SECRET_KEY_HERE'
    )
    ->build();



$response = $sdk->environmentVariables->retrieve(
    variableKey: 'BASE_URL'
);

if ($response->environmentVariableResponseDto !== null) {
    // handle response
}
{
  "_id": "<string>",
  "_organizationId": "<string>",
  "key": "<string>",
  "type": "string",
  "isSecret": true,
  "values": [
    {
      "_environmentId": "<string>",
      "value": "<string>"
    }
  ],
  "createdAt": "<string>",
  "updatedAt": "<string>"
}

Authorizations

Authorization
string
header
required

API key authentication. Allowed headers-- "Authorization: ApiKey <novu_secret_key>".

Headers

idempotency-key
string

A header for idempotency purposes

Path Parameters

variableKey
string
required

The unique key of the environment variable (e.g. BASE_URL)

Response

OK

_id
string
required
_organizationId
string
required
key
string
required
type
enum<string>
required
Available options:
string
isSecret
boolean
required
values
object[]
required
createdAt
string
required
updatedAt
string
required