README.md in colissimo_label-0.4.0 vs README.md in colissimo_label-0.5.0
- old
+ new
@@ -77,11 +77,11 @@
).perform
```
It will return an array of relay points with the following data:
-```ruby
+```
{
:pickup_id,
:name,
:address,
:postcode,
@@ -136,10 +136,41 @@
email: 'Email of the addressee'
}
).perform
```
+For a national address and delivered to a relay point:
+
+```ruby
+parcel_number = ColissimoLabel::GenerateLabel.new(
+ 'label_filename', # Name of the file generated
+ 'FR', # Normalized country code of the destination
+ 9.99, # Amount of the shipping fees (paid by the customer)
+ {
+ company_name: 'Sender company name',
+ address: 'Address',
+ city: 'City',
+ postcode: 'Postcode',
+ country_code: 'Normalized country code (ex: FR)'
+ },
+ {
+ last_name: 'Last name of the addressee',
+ first_name: 'First name of the addressee',
+ address_bis: 'Address bis of the addressee',
+ address: 'Address of the addressee',
+ city: 'City of the addressee',
+ postcode: 'Postcode of the addressee',
+ country_code: 'Normalized country code of the addressee',
+ phone: 'Phone number of the addressee',
+ mobile: 'Mobile number of the addressee',
+ email: 'Email of the addressee'
+ },
+ pickup_id: 'pickup ID',
+ pickup_type: 'BPR or A2P'
+ ).perform
+```
+
For a foreign address (which required customs declaration):
```ruby
parcel_number = ColissimoLabel::GenerateLabel.new(
'label_filename', # Name of the file generated
@@ -162,11 +193,11 @@
country_code: 'Normalized country code of the addressee',
phone: 'Phone number of the addressee',
mobile: 'Mobile number of the addressee',
email: 'Email of the addressee'
},
- 2, # Total weight of the package
- [ # Details content of your package
+ customs_total_weight: 2, # Total weight of the package
+ customs_data: [ # Details content of your package
{
description: 'Product description',
quantity: 1,
weight: 2,
item_price: 100,