Skip to content

Add Linode historical network transfer endpoint #254

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
77 changes: 77 additions & 0 deletions openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5545,6 +5545,83 @@ paths:
- lang: CLI
source: >
linode-cli linodes transfer-view 123
/linode/instances/{linodeId}/transfer/{year}/{month}:
parameters:
- name: linodeId
in: path
description: ID of the Linode to look up.
required: true
schema:
type: integer
- name: year
in: path
description: Numeric value representing the year to look up.
required: true
schema:
type: integer
minimum: 2000
maximum: 2037
- name: month
in: path
description: Numeric value representing the month to look up.
required: true
schema:
type: integer
minimum: 1
maximum: 12
x-linode-cli-command: linodes
get:
x-linode-grant: read_only
tags:
- Linode Instances
summary: View Network Transfer (year/month)
description: >
Returns a Linode's network transfer statistics for a specific month. The year/month
values must be either a date in the past, or the current month.
operationId: getLinodeTransferByYearMonth
x-linode-cli-skip: true
x-linode-cli-action: transfer-month
security:
- personalAccessToken: []
- oauth:
- linodes:read_only
responses:
'200':
description: >
A collection of the specified Linode's network transfer statistics for the requested
month.
content:
application/json:
schema:
properties:
bytes_in:
type: integer
description: >
The amount of inbound public network traffic received by this Linode, in
bytes, for a specific year/month.
example: 30471077120
readOnly: true
bytes_out:
type: integer
description: >
The amount of outbound public network traffic sent by this Linode, in bytes,
for a specific year/month.
example: 22956600198
readOnly: true
bytes_total:
type: integer
description: >
The total amount of public network traffic sent and received by this Linode,
in bytes, for a specific year/month.
example: 53427677318
readOnly: true
default:
$ref: '#/components/responses/ErrorResponse'
x-code-samples:
- lang: Shell
source: >
curl -H "Authorization: Bearer $TOKEN" \
https://api.linode.com/v4/linode/instances/123/transfer/2018/01
/linode/instances/{linodeId}/stats:
parameters:
- name: linodeId
Expand Down