-
Release Notes
- July 8, 2024
- May 22, 2024
- April 17, 2024
- March 20, 2024
- February 22, 2024
- January 18, 2024
- 2023 Releases
- 2022 Releases
-
2021 Releases
- December 20, 2021
- December 1, 2021
- November 22, 2021
- November 4, 2021
- October 26, 2021
- September 30, 2021
- September 22, 2021
- September 2, 2021
- August 16, 2021
- August 2, 2021
- July 19, 2021
- July 1, 2021
- June 17, 2021
- June 1, 2021
- April 30, 2021
- April 8, 2021
- March 25, 2021
- March 15, 2021
- February 25, 2021
- February 8, 2021
- January 28, 2021
- January 21, 2021
- January 13, 2021
- 2020 Releases
- Getting Started
- Ports
- Cross Connects
- Point-to-Point
- Virtual Circuits
- Cloud Connections
- Cloud Router
- Marketplace & IX
- Administration
- Billing
- Troubleshooting & FAQ
- Technical Reference
- Partners Portal
- API & Automation
Manage a Capacity Burst via the API
For more information about bursts and which virtual circuits are eligible, see Capacity Bursts.
Before you begin
Ensure you have a bearer token authorizing all your API calls. For information on authorizing calls, see one of the following pages:
- Using Postman with the PacketFabric API
- Using cURL with the PacketFabric API
- Using Python Requests with the PacketFabric API
API reference
Parameters and attributes
To provision a marketplace connection, you will need the following information:
- Header row
- Parameter
- Required
- Description
- Row 1
vc_circuit_id
string- Yes (parameter)
- The ID of the virtual circuit. You can get the circuit ID from
https://api.packetfabric.com/v2/services
.
- Row 1
speed
string- Yes
- Burst speed in Mbps. This bandwidth will be added to the existing circuit speed. Must be a multiple of 100Mbps.
Get your virtual circuit ID
The following GET call will return a list of your ports: https://api.packetfabric.com/v2/services
Note the circuit ID of the connection you want to burst.
Apply the burst
Postman
-
Open Postman and click the plus icon to add a new request.
-
Select POST from the drop-down menu that appears before the URL field.
-
Enter the following API call into the URL field, substituting the ID of the virtual circuit:
https://api.packetfabric.com/v2/services/{vc_circuit_id}/burst
-
Select the Body subtab and then select raw. Select JSON from the drop-down menu (see below for an example that you can copy and paste):
-
In the space below, set your parameters. For example (include the curly brackets):
-
Click Send.
JSON sample
Here is a JSON sample for you to copy and then modify accordingly:
{
"speed": "300Mbps"
}
cURL
Unix:
curl -X POST https://api.packetfabric.com/v2/services/{vc_circuit_id}/burst -d '{"speed":"300Mbps"}' -H "accept: */*" -H "Authorization: Bearer replace_with_api_key"
Windows:
curl -X POST https://api.packetfabric.com/v2/services/{vc_circuit_id}/burst -d "{\"speed\":\"300Mbps\"}" -H "accept: */*" -H "Authorization: Bearer replace_with_api_key"
Requests
import requests
api_key = 'replace_with_api_key'
request_header = {
'Authorization': f'Bearer {api_key}'
}
# Replace {vc_circuit_id} with the string you obtained earlier
post_url = 'placeholder_api.packetfabric.com/v2/services/{vc_circuit_id}/burst'
post_json = {
"speed": "300Mbps"
}
api = requests.post(post_url, json=post_json, headers=request_header)
print(api)
Modify the burst
If an existing burst exists, repeat the same request above with a new burst speed. The new speed replaces the previous burst speed.
For example, in the examples above we added a 300Mbps burst. If the circuit was initially 50Mbps, the capacity would be 350Mbps while the burst is in place.
If we want to have a 500Mbps burst, then simply repeat the call above with a speed of 500Mbps (using cURL):
curl -X POST https://api.packetfabric.com/v2/services/{vc_circuit_id}/burst -d '{"speed":"500Mbps"}' -H "accept: */*" -H "Authorization: Bearer replace_with_api_key"
This would result in a virtual circuit with 550Mbps of capacity (again assuming the virtual circuit was initially only 50Mbps).
Delete the burst
Use the same URL but as a DELETE request: https://api.packetfabric.com/v2/services/{vc_circuit_id}/burst
Postman
You do not need to send any data. Simply use the drop-down menu to change the request type to DELETE:
cURL
curl -X DELETE https://api.packetfabric.com/v2/services/{vc_circuit_id}/burst -H "accept: */*" -H "Authorization: Bearer replace_with_api_key"
Requests
import requests
api_key = 'replace_with_api_key'
request_header = {
'Authorization': f'Bearer {api_key}'
}
# Replace {vc_circuit_id} with the string you obtained earlier
delete_url = 'placeholder_api.packetfabric.com/v2/services/{vc_circuit_id}/burst'
api = requests.delete(delete_url, headers=request_header)
print(api)
Updated on 10 Jul 2022