Skip to content
This repository was archived by the owner on Sep 17, 2025. It is now read-only.

Commit e18be06

Browse files
authored
Merge pull request #50 from JeremyDunn/async-transaction-service
Async transaction service
2 parents ab8fc42 + d2e4946 commit e18be06

22 files changed

+1515
-0
lines changed

CHANGELOG.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,25 @@
11
# CHANGELOG
22

3+
## 2.3 (released 2017-11-02)
4+
- Added ASYNC Transaction Service
5+
6+
|Service|Version|
7+
|---|---|
8+
|Address Validation|2|
9+
|Close|2|
10+
|Courier Dispatch|3|
11+
|Locator|2|
12+
|Package Movement Information|5|
13+
|Pickup|3|
14+
|Rate|10|
15+
|Return Tag|1|
16+
|Ship|12|
17+
|Track|5|
18+
|Upload Document|1|
19+
|Open Ship|11|
20+
|Validation Availability and Commitment Service|6|
21+
|ASYNC Transaction Service|4|
22+
323
## 2.2 (released 2017-08-19)
424
- Added Validation Availability and Commitment Service
525

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,13 @@ Each web service has it's own class namespace. See the official FedEx web servic
2323
* [Upload Document Service](src/FedEx/UploadDocumentService)
2424
* [Open Ship Service](src/FedEx/OpenShipService)
2525
* [Validation Availability and Commitment Service](src/FedEx/ValidationAvailabilityAndCommitmentService)
26+
* [ASYNC Transaction Service](src/FedEx/AsyncService)
27+
28+
## Installation
29+
30+
```
31+
composer require jeremy-dunn/php-fedex-api-wrapper
32+
```
2633

2734
## Using the library
2835

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
<?php
2+
namespace FedEx\AsyncService\ComplexType;
3+
4+
use FedEx\AbstractComplexType;
5+
6+
/**
7+
* ArtifactPart
8+
*
9+
* @author Jeremy Dunn <[email protected]>
10+
* @package PHP FedEx API wrapper
11+
* @subpackage ASync Service
12+
*
13+
* @property int $SequenceNumber
14+
* @property string $Contents
15+
16+
*/
17+
class ArtifactPart extends AbstractComplexType
18+
{
19+
/**
20+
* Name of this complex type
21+
*
22+
* @var string
23+
*/
24+
protected $name = 'ArtifactPart';
25+
26+
/**
27+
* Specifies the sequence of this part of the artifact.
28+
*
29+
* @param int $sequenceNumber
30+
* @return $this
31+
*/
32+
public function setSequenceNumber($sequenceNumber)
33+
{
34+
$this->values['SequenceNumber'] = $sequenceNumber;
35+
return $this;
36+
}
37+
38+
/**
39+
* Specifies the contents of this retrieved artifact part.
40+
*
41+
* @param string $contents
42+
* @return $this
43+
*/
44+
public function setContents($contents)
45+
{
46+
$this->values['Contents'] = $contents;
47+
return $this;
48+
}
49+
}
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
<?php
2+
namespace FedEx\AsyncService\ComplexType;
3+
4+
use FedEx\AbstractComplexType;
5+
6+
/**
7+
* Specifies the details about the criteria used for artifact selection during retrieval.
8+
*
9+
* @author Jeremy Dunn <[email protected]>
10+
* @package PHP FedEx API wrapper
11+
* @subpackage ASync Service
12+
*
13+
* @property string $AccessReference
14+
* @property \FedEx\AsyncService\SimpleType\ArtifactType|string $Type
15+
* @property string $ReferenceId
16+
17+
*/
18+
class ArtifactRetrievalFilter extends AbstractComplexType
19+
{
20+
/**
21+
* Name of this complex type
22+
*
23+
* @var string
24+
*/
25+
protected $name = 'ArtifactRetrievalFilter';
26+
27+
/**
28+
* Set AccessReference
29+
*
30+
* @param string $accessReference
31+
* @return $this
32+
*/
33+
public function setAccessReference($accessReference)
34+
{
35+
$this->values['AccessReference'] = $accessReference;
36+
return $this;
37+
}
38+
39+
/**
40+
* Set Type
41+
*
42+
* @param \FedEx\AsyncService\SimpleType\ArtifactType|string $type
43+
* @return $this
44+
*/
45+
public function setType($type)
46+
{
47+
$this->values['Type'] = $type;
48+
return $this;
49+
}
50+
51+
/**
52+
* Set ReferenceId
53+
*
54+
* @param string $referenceId
55+
* @return $this
56+
*/
57+
public function setReferenceId($referenceId)
58+
{
59+
$this->values['ReferenceId'] = $referenceId;
60+
return $this;
61+
}
62+
}
Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
<?php
2+
namespace FedEx\AsyncService\ComplexType;
3+
4+
use FedEx\AbstractComplexType;
5+
6+
/**
7+
* Descriptive data for the client submitting a transaction.
8+
*
9+
* @author Jeremy Dunn <[email protected]>
10+
* @package PHP FedEx API wrapper
11+
* @subpackage ASync Service
12+
*
13+
* @property string $AccountNumber
14+
* @property string $MeterNumber
15+
* @property string $MeterInstance
16+
* @property string $IntegratorId
17+
* @property \FedEx\AsyncService\SimpleType\ExpressRegionCode|string $Region
18+
* @property Localization $Localization
19+
20+
*/
21+
class ClientDetail extends AbstractComplexType
22+
{
23+
/**
24+
* Name of this complex type
25+
*
26+
* @var string
27+
*/
28+
protected $name = 'ClientDetail';
29+
30+
/**
31+
* The FedEx account number associated with this transaction.
32+
*
33+
* @param string $accountNumber
34+
* @return $this
35+
*/
36+
public function setAccountNumber($accountNumber)
37+
{
38+
$this->values['AccountNumber'] = $accountNumber;
39+
return $this;
40+
}
41+
42+
/**
43+
* This number is assigned by FedEx and identifies the unique device from which the request is originating
44+
*
45+
* @param string $meterNumber
46+
* @return $this
47+
*/
48+
public function setMeterNumber($meterNumber)
49+
{
50+
$this->values['MeterNumber'] = $meterNumber;
51+
return $this;
52+
}
53+
54+
/**
55+
* Set MeterInstance
56+
*
57+
* @param string $meterInstance
58+
* @return $this
59+
*/
60+
public function setMeterInstance($meterInstance)
61+
{
62+
$this->values['MeterInstance'] = $meterInstance;
63+
return $this;
64+
}
65+
66+
/**
67+
* Only used in transactions which require identification of the FedEx Office integrator.
68+
*
69+
* @param string $integratorId
70+
* @return $this
71+
*/
72+
public function setIntegratorId($integratorId)
73+
{
74+
$this->values['IntegratorId'] = $integratorId;
75+
return $this;
76+
}
77+
78+
/**
79+
* Indicates the region from which the transaction is submitted.
80+
*
81+
* @param \FedEx\AsyncService\SimpleType\ExpressRegionCode|string $region
82+
* @return $this
83+
*/
84+
public function setRegion($region)
85+
{
86+
$this->values['Region'] = $region;
87+
return $this;
88+
}
89+
90+
/**
91+
* The language to be used for human-readable Notification.localizedMessages in responses to the request containing this ClientDetail object. Different requests from the same client may contain different Localization data. (Contrast with TransactionDetail.localization, which governs data payload language/translation.)
92+
*
93+
* @param Localization $localization
94+
* @return $this
95+
*/
96+
public function setLocalization(Localization $localization)
97+
{
98+
$this->values['Localization'] = $localization;
99+
return $this;
100+
}
101+
}
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
<?php
2+
namespace FedEx\AsyncService\ComplexType;
3+
4+
use FedEx\AbstractComplexType;
5+
6+
/**
7+
* Identifies the representation of human-readable text.
8+
*
9+
* @author Jeremy Dunn <[email protected]>
10+
* @package PHP FedEx API wrapper
11+
* @subpackage ASync Service
12+
*
13+
* @property string $LanguageCode
14+
* @property string $LocaleCode
15+
16+
*/
17+
class Localization extends AbstractComplexType
18+
{
19+
/**
20+
* Name of this complex type
21+
*
22+
* @var string
23+
*/
24+
protected $name = 'Localization';
25+
26+
/**
27+
* Two-letter code for language (e.g. EN, FR, etc.)
28+
*
29+
* @param string $languageCode
30+
* @return $this
31+
*/
32+
public function setLanguageCode($languageCode)
33+
{
34+
$this->values['LanguageCode'] = $languageCode;
35+
return $this;
36+
}
37+
38+
/**
39+
* Two-letter code for the region (e.g. us, ca, etc..).
40+
*
41+
* @param string $localeCode
42+
* @return $this
43+
*/
44+
public function setLocaleCode($localeCode)
45+
{
46+
$this->values['LocaleCode'] = $localeCode;
47+
return $this;
48+
}
49+
}

0 commit comments

Comments
 (0)