Skip to content

Commit 9eac366

Browse files
committed
Generate the service code
1 parent cbe53a5 commit 9eac366

File tree

58 files changed

+1937
-3
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+1937
-3
lines changed

composer.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,10 @@
1111
"Amazon Incentives API"
1212
],
1313
"require": {
14-
"php": "^8.1"
14+
"php": "^8.1",
15+
"ext-SimpleXML": "*",
16+
"ext-dom": "*",
17+
"async-aws/core": "^1.9"
1518
},
1619
"require-dev": {
1720
"async-aws/code-generator": "dev-master",

phpstan.neon

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
parameters:
2-
level: max
2+
level: 6
3+
treatPhpDocTypesAsCertain: false
4+
checkMissingIterableValueType: false
35
paths:
46
- src/
57
- tests/
68

79
includes:
8-
- phar://phpstan.phar/conf/bleedingEdge.neon
910
- vendor/phpstan/phpstan-deprecation-rules/rules.neon
1011
- vendor/phpstan/phpstan-phpunit/extension.neon
1112
- vendor/phpstan/phpstan-phpunit/rules.neon

src/AmazonIncentivesClient.php

Lines changed: 407 additions & 0 deletions
Large diffs are not rendered by default.

src/Enum/CurrencyCode.php

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
<?php
2+
3+
namespace Incenteev\AsyncAmazonIncentives\Enum;
4+
5+
final class CurrencyCode
6+
{
7+
public const AED = 'AED';
8+
public const AUD = 'AUD';
9+
public const CAD = 'CAD';
10+
public const EUR = 'EUR';
11+
public const GBP = 'GBP';
12+
public const JPY = 'JPY';
13+
public const MXN = 'MXN';
14+
public const PLN = 'PLN';
15+
public const SAR = 'SAR';
16+
public const SEK = 'SEK';
17+
public const SGD = 'SGD';
18+
public const TRY = 'TRY';
19+
public const USD = 'USD';
20+
21+
public static function exists(string $value): bool
22+
{
23+
return isset([
24+
self::AED => true,
25+
self::AUD => true,
26+
self::CAD => true,
27+
self::EUR => true,
28+
self::GBP => true,
29+
self::JPY => true,
30+
self::MXN => true,
31+
self::PLN => true,
32+
self::SAR => true,
33+
self::SEK => true,
34+
self::SGD => true,
35+
self::TRY => true,
36+
self::USD => true,
37+
][$value]);
38+
}
39+
}

src/Enum/Status.php

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?php
2+
3+
namespace Incenteev\AsyncAmazonIncentives\Enum;
4+
5+
final class Status
6+
{
7+
public const FAILURE = 'FAILURE';
8+
public const RESEND = 'RESEND';
9+
public const SUCCESS = 'SUCCESS';
10+
11+
public static function exists(string $value): bool
12+
{
13+
return isset([
14+
self::FAILURE => true,
15+
self::RESEND => true,
16+
self::SUCCESS => true,
17+
][$value]);
18+
}
19+
}
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?php
2+
3+
namespace Incenteev\AsyncAmazonIncentives\Exception;
4+
5+
use AsyncAws\Core\Exception\Http\ClientException;
6+
7+
final class AccountHasProblemsException extends ClientException
8+
{
9+
}
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?php
2+
3+
namespace Incenteev\AsyncAmazonIncentives\Exception;
4+
5+
use AsyncAws\Core\Exception\Http\ClientException;
6+
7+
final class ActiveContractNotFoundException extends ClientException
8+
{
9+
}
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?php
2+
3+
namespace Incenteev\AsyncAmazonIncentives\Exception;
4+
5+
use AsyncAws\Core\Exception\Http\ClientException;
6+
7+
final class AmountBelowMinThresholdException extends ClientException
8+
{
9+
}

src/Exception/BadInputException.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?php
2+
3+
namespace Incenteev\AsyncAmazonIncentives\Exception;
4+
5+
use AsyncAws\Core\Exception\Http\ClientException;
6+
7+
final class BadInputException extends ClientException
8+
{
9+
}
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?php
2+
3+
namespace Incenteev\AsyncAmazonIncentives\Exception;
4+
5+
use AsyncAws\Core\Exception\Http\ClientException;
6+
7+
final class BlockedCustomerException extends ClientException
8+
{
9+
}

0 commit comments

Comments
 (0)