openapi: 3.2.0 info: contact: email: support@linode.com name: Linode url: https://linode.com description: Add a Cloud Computing instance so you can build, release, and scale applications faster with virtual machines. license: name: Apache 2.0 url: https://www.apache.org/licenses/LICENSE-2.0.html title: 'Akamai: Linode Promo credits API' version: 4.215.0 servers: - url: https://api.linode.com tags: - description: Use these operations to manage any promotional codes you've been granted for special offers. name: Promo credits paths: /{apiVersion}/account/promo-codes: parameters: - description: __Enum__ Call either the `v4` URL, or `v4beta` for operations still in Beta. example: '{{apiVersion}}' in: path name: apiVersion required: true schema: enum: - v4 - v4beta type: string x-akamai: file-path: parameters/api-version-path.yaml x-akamai: file-path: paths/promo-codes.yaml path-info: /{apiVersion}/account/promo-codes x-linode-cli-command: account post: description: 'Adds an expiring Promo Credit to your account. The following restrictions apply: - Your account needs to be less than 90 days old. - You can''t already have a Promo Credit on your account. - The user making the request needs to be unrestricted. You can run the Update a user operation to change a user''s restricted status. - The `promo_code` needs to be valid and unexpired. __Parent and child accounts__ In a parent and child account environment, the following apply: - Child account users can''t run this operation. These users don''t have access to billing-related operations. > --- - __CLI__. ``` linode-cli account \ promo-add \ --promo-code abcdefABCDEF1234567890 ``` Learn more... - __OAuth scopes__. ``` account:read_only ``` Learn more...' externalDocs: description: See documentation for this operation in Akamai's Linode API url: https://techdocs.akamai.com/linode-api/reference/post-promo-credit operationId: post-promo-credit requestBody: content: application/json: schema: additionalProperties: false properties: promo_code: description: The Promo Code. example: '{{promo_code}}' maxLength: 32 minLength: 1 type: string required: - promo_code type: object x-akamai: file-path: schemas/added-post-promo-credit.yaml x-example: x-ref: ../examples/post-promo-credit.json description: Enter a Promo Code to add its associated credit to your Account. responses: '200': content: application/json: schema: additionalProperties: false description: '__Read-only__ Promotions generally offer a set amount of credit that can be used toward your Linode services, and the promotion expires after a specified date. As well, a monthly cap on the promotional offer is set. Simply put, a promotion offers a certain amount of credit month, until either the expiration date is passed, or until the total promotional credit is used, whichever comes first.' properties: credit_monthly_cap: description: The amount available to spend per month. example: '10.00' type: string x-linode-cli-display: 5 credit_remaining: description: The total amount of credit left for this promotion. example: '50.00' type: string x-linode-cli-display: 3 description: description: A detailed description of this promotion. example: Receive up to $10 off your services every month for 6 months! Unused credits will expire once this promotion period ends. type: string expire_dt: description: When this promotion's credits expire. example: '2018-01-31T23:59:59' type: string x-linode-cli-display: 2 image_url: description: The location of an image for this promotion. example: https://linode.com/10_a_month_promotion.svg type: string service_type: description: The service to which this promotion applies. enum: - all - backup - blockstorage - db_mysql - ip_v4 - linode - linode_disk - linode_memory - longview - managed - nodebalancer - objectstorage - placement_group - transfer_tx example: all type: string x-linode-cli-display: 1 summary: description: Short details of this promotion. example: $10 off your Linode a month! type: string x-linode-cli-display: 10 this_month_credit_remaining: description: The amount of credit left for this month for this promotion. example: '10.00' type: string x-linode-cli-display: 4 readOnly: true type: object x-akamai: file-path: schemas/promotion.yaml x-example: x-ref: ../examples/post-promo-credit-200.json description: Promo Credit successfully added. default: content: application/json: schema: additionalProperties: false properties: errors: items: additionalProperties: false description: An object for describing a single error that occurred during the processing of a request. properties: field: description: The field in the request that caused this error. This may be a path, separated by periods in the case of nested fields. In some cases this may come back as `null` if the error is not specific to any single element of the request. example: fieldname type: string reason: description: What happened to cause this error. In most cases, this can be fixed immediately by changing the data you sent in the request, but in some cases you will be instructed to [Open a support ticket](https://techdocs.akamai.com/linode-api/reference/post-ticket) or perform some other action before you can complete the request successfully. example: fieldname must be a valid value type: string type: object x-akamai: file-path: schemas/error-object.yaml type: array type: object description: See [Errors](https://techdocs.akamai.com/linode-api/reference/errors) for the range of possible error response codes. security: - personalAccessToken: [] - oauth: - account:read_only summary: Add a promo credit tags: - Promo credits x-akamai: tabs: - syntax: "linode-cli account \\\n promo-add \\\n --promo-code abcdefABCDEF1234567890" title: CLI url: https://techdocs.akamai.com/cloud-computing/docs/getting-started-with-the-linode-cli - syntax: account:read_only title: OAuth scopes url: https://techdocs.akamai.com/linode-api/reference/get-started#oauth x-linode-cli-action: promo-add x-linode-grant: unrestricted only components: securitySchemes: oauth: flows: authorizationCode: authorizationUrl: https://login.linode.com/oauth/authorize scopes: account:read_only: Allows access to GET information about your account. account:read_write: Allows access to all endpoints related to your account. domains:read_only: Allows access to GET Domains on your account. domains:read_write: Allows access to all Domain endpoints. events:read_only: Allows access to GET your Events. events:read_write: Allows access to all endpoints related to your Events. firewall:read_only: Allows access to GET information about your Firewalls. firewall:read_write: Allows access to all Firewall endpoints. images:read_only: Allows access to GET your Images. images:read_write: Allows access to all endpoints related to your Images. ips:read_only: Allows access to GET your ips. ips:read_write: Allows access to all endpoints related to your ips. linodes:read_only: Allows access to GET Linodes on your account. linodes:read_write: Allow access to all endpoints related to your Linodes. lke:read_only: Allows access to GET LKE Clusters on your account. lke:read_write: Allows access to all endpoints related to LKE Clusters on your account. longview:read_only: Allows access to GET your Longview Clients. longview:read_write: Allows access to all endpoints related to your Longview Clients. monitor:read-write: Allows access to all Monitor (Akamai Cloud Pulse) endpoints. monitor:read_only: Allows access to Monitor (Akamai Cloud Pulse) data. nodebalancers:read_only: Allows access to GET NodeBalancers on your account. nodebalancers:read_write: Allows access to all NodeBalancer endpoints. object_storage:read_only: Allows access to GET information related to your Object Storage. object_storage:read_write: Allows access to all Object Storage endpoints. stackscripts:read_only: Allows access to GET your StackScripts. stackscripts:read_write: Allows access to all endpoints related to your StackScripts. volumes:read_only: Allows access to GET your Volumes. volumes:read_write: Allows access to all endpoints related to your Volumes. vpc:read_write: Allows access to all endpoints related to VPC and Subnet creation, updating, and deletion. tokenUrl: https://login.linode.com/oauth/token type: oauth2 personalAccessToken: scheme: bearer type: http externalDocs: description: See documentation for Akamai's Linode API url: https://techdocs.akamai.com/linode-api/reference x-readme: samples-languages: - curl - python - node