ShippingRate.php 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <?php
  2. // File generated from our OpenAPI spec
  3. namespace Stripe;
  4. /**
  5. * Shipping rates describe the price of shipping presented to your customers and
  6. * can be applied to <a
  7. * href="https://stripe.com/docs/payments/checkout/shipping">Checkout Sessions</a>
  8. * to collect shipping costs.
  9. *
  10. * @property string $id Unique identifier for the object.
  11. * @property string $object String representing the object's type. Objects of the same type share the same value.
  12. * @property bool $active Whether the shipping rate can be used for new purchases. Defaults to <code>true</code>.
  13. * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
  14. * @property null|\Stripe\StripeObject $delivery_estimate The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
  15. * @property null|string $display_name The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
  16. * @property \Stripe\StripeObject $fixed_amount
  17. * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
  18. * @property \Stripe\StripeObject $metadata Set of <a href="https://stripe.com/docs/api/metadata">key-value pairs</a> that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
  19. * @property null|string $tax_behavior Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of <code>inclusive</code>, <code>exclusive</code>, or <code>unspecified</code>.
  20. * @property null|string|\Stripe\TaxCode $tax_code A <a href="https://stripe.com/docs/tax/tax-codes">tax code</a> ID. The Shipping tax code is <code>txcd_92010001</code>.
  21. * @property string $type The type of calculation to use on the shipping rate. Can only be <code>fixed_amount</code> for now.
  22. */
  23. class ShippingRate extends ApiResource
  24. {
  25. const OBJECT_NAME = 'shipping_rate';
  26. use ApiOperations\All;
  27. use ApiOperations\Create;
  28. use ApiOperations\Retrieve;
  29. use ApiOperations\Update;
  30. const TAX_BEHAVIOR_EXCLUSIVE = 'exclusive';
  31. const TAX_BEHAVIOR_INCLUSIVE = 'inclusive';
  32. const TAX_BEHAVIOR_UNSPECIFIED = 'unspecified';
  33. const TYPE_FIXED_AMOUNT = 'fixed_amount';
  34. }