Skip to content

Commit 62f654f

Browse files
author
Andrey Helldar
committed
Added contracts for the Cashier Tinkoff Driver
1 parent 92fef95 commit 62f654f

File tree

3 files changed

+39
-0
lines changed

3 files changed

+39
-0
lines changed
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<?php
2+
3+
namespace Helldar\Contracts\Cashier\Authentication;
4+
5+
interface Auth
6+
{
7+
public function accessToken(Client $client): Credentials;
8+
}
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<?php
2+
3+
namespace Helldar\Contracts\Cashier\Authentication;
4+
5+
interface Client
6+
{
7+
public function clientId(string $client_id): self;
8+
9+
public function getClientId(): string;
10+
11+
public function clientSecret(string $client_secret): self;
12+
13+
public function getClientSecret(): string;
14+
}
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<?php
2+
3+
namespace Helldar\Contracts\Cashier\Authentication;
4+
5+
use DateTimeInterface;
6+
use Helldar\Contracts\Support\Arrayable;
7+
8+
interface Credentials extends Arrayable
9+
{
10+
public function __construct(array $items = []);
11+
12+
public function getClientId(): string;
13+
14+
public function getAccessToken(): string;
15+
16+
public function getExpiresIn(): DateTimeInterface;
17+
}

0 commit comments

Comments
 (0)