-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathBearerAuthenticationPlan.php
More file actions
50 lines (43 loc) · 1.22 KB
/
Copy pathBearerAuthenticationPlan.php
File metadata and controls
50 lines (43 loc) · 1.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
<?php
namespace Vapi\Types;
use Vapi\Core\Json\JsonSerializableType;
use Vapi\Core\Json\JsonProperty;
class BearerAuthenticationPlan extends JsonSerializableType
{
/**
* @var ?string $token This is the bearer token value.
*/
#[JsonProperty('token')]
public ?string $token;
/**
* @var ?string $headerName This is the header name where the bearer token will be sent. Defaults to 'Authorization'.
*/
#[JsonProperty('headerName')]
public ?string $headerName;
/**
* @var ?bool $bearerPrefixEnabled Whether to include the 'Bearer ' prefix in the header value. Defaults to true.
*/
#[JsonProperty('bearerPrefixEnabled')]
public ?bool $bearerPrefixEnabled;
/**
* @param array{
* token?: ?string,
* headerName?: ?string,
* bearerPrefixEnabled?: ?bool,
* } $values
*/
public function __construct(
array $values,
) {
$this->token = $values['token'] ?? null;
$this->headerName = $values['headerName'] ?? null;
$this->bearerPrefixEnabled = $values['bearerPrefixEnabled'] ?? null;
}
/**
* @return string
*/
public function __toString(): string
{
return $this->toJson();
}
}