Skip to content

Latest commit

 

History

History
423 lines (265 loc) · 12 KB

VersionApi.md

File metadata and controls

423 lines (265 loc) · 12 KB

VersionApi

Note

All URIs are relative to https://api.fastly.com

Method HTTP request Description
activate_service_version PUT /service/{service_id}/version/{version_id}/activate Activate a service version
activate_service_version_environment PUT /service/{service_id}/version/{version_id}/activate/{environment_name} Activate a service version on the specified environment
clone_service_version PUT /service/{service_id}/version/{version_id}/clone Clone a service version
create_service_version POST /service/{service_id}/version Create a service version
deactivate_service_version PUT /service/{service_id}/version/{version_id}/deactivate Deactivate a service version
deactivate_service_version_environment PUT /service/{service_id}/version/{version_id}/deactivate/{environment_name} Deactivate a service version on an environment
get_service_version GET /service/{service_id}/version/{version_id} Get a version of a service
list_service_versions GET /service/{service_id}/version List versions of a service
lock_service_version PUT /service/{service_id}/version/{version_id}/lock Lock a service version
update_service_version PUT /service/{service_id}/version/{version_id} Update a service version
validate_service_version GET /service/{service_id}/version/{version_id}/validate Validate a service version

activate_service_version

Activate the current version.

let cfg = &Configuration::default();
let params = ActivateServiceVersionParams {
    // parameters
};
activate_service_version(cfg, params)

Parameters

Name Type Description Required Notes
service_id String Alphanumeric string identifying the service. [required]
version_id i32 Integer identifying a service version. [required]

Return type

crate::models::VersionResponse

Authorization

token

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to README]

activate_service_version_environment

Activate a version on a given environment, i.e. "staging"

let cfg = &Configuration::default();
let params = ActivateServiceVersionEnvironmentParams {
    // parameters
};
activate_service_version_environment(cfg, params)

Parameters

Name Type Description Required Notes
service_id String Alphanumeric string identifying the service. [required]
version_id i32 Integer identifying a service version. [required]
environment_name crate::models::EnvironmentName [required]

Return type

crate::models::VersionResponse

Authorization

token

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to README]

clone_service_version

Clone the current configuration into a new version.

let cfg = &Configuration::default();
let params = CloneServiceVersionParams {
    // parameters
};
clone_service_version(cfg, params)

Parameters

Name Type Description Required Notes
service_id String Alphanumeric string identifying the service. [required]
version_id i32 Integer identifying a service version. [required]

Return type

crate::models::Version

Authorization

token

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to README]

create_service_version

Create a version for a particular service.

let cfg = &Configuration::default();
let params = CreateServiceVersionParams {
    // parameters
};
create_service_version(cfg, params)

Parameters

Name Type Description Required Notes
service_id String Alphanumeric string identifying the service. [required]

Return type

crate::models::VersionCreateResponse

Authorization

token

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to README]

deactivate_service_version

Deactivate the current version.

let cfg = &Configuration::default();
let params = DeactivateServiceVersionParams {
    // parameters
};
deactivate_service_version(cfg, params)

Parameters

Name Type Description Required Notes
service_id String Alphanumeric string identifying the service. [required]
version_id i32 Integer identifying a service version. [required]

Return type

crate::models::VersionResponse

Authorization

token

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to README]

deactivate_service_version_environment

Deactivate the current version on a given environment, i.e. "staging"

let cfg = &Configuration::default();
let params = DeactivateServiceVersionEnvironmentParams {
    // parameters
};
deactivate_service_version_environment(cfg, params)

Parameters

Name Type Description Required Notes
service_id String Alphanumeric string identifying the service. [required]
version_id i32 Integer identifying a service version. [required]
environment_name crate::models::EnvironmentName [required]

Return type

crate::models::VersionResponse

Authorization

token

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to README]

get_service_version

Get the version for a particular service.

let cfg = &Configuration::default();
let params = GetServiceVersionParams {
    // parameters
};
get_service_version(cfg, params)

Parameters

Name Type Description Required Notes
service_id String Alphanumeric string identifying the service. [required]
version_id i32 Integer identifying a service version. [required]

Return type

crate::models::VersionResponse

Authorization

token

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to README]

list_service_versions

List the versions for a particular service.

let cfg = &Configuration::default();
let params = ListServiceVersionsParams {
    // parameters
};
list_service_versions(cfg, params)

Parameters

Name Type Description Required Notes
service_id String Alphanumeric string identifying the service. [required]

Return type

Vec<crate::models::VersionResponse>

Authorization

token

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to README]

lock_service_version

Locks the specified version.

let cfg = &Configuration::default();
let params = LockServiceVersionParams {
    // parameters
};
lock_service_version(cfg, params)

Parameters

Name Type Description Required Notes
service_id String Alphanumeric string identifying the service. [required]
version_id i32 Integer identifying a service version. [required]

Return type

crate::models::Version

Authorization

token

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to README]

update_service_version

Update a particular version for a particular service.

let cfg = &Configuration::default();
let params = UpdateServiceVersionParams {
    // parameters
};
update_service_version(cfg, params)

Parameters

Name Type Description Required Notes
service_id String Alphanumeric string identifying the service. [required]
version_id i32 Integer identifying a service version. [required]
active Option<bool> Whether this is the active version or not. [default to false]
comment Option<String> A freeform descriptive note.
deployed Option<bool> Unused at this time.
locked Option<bool> Whether this version is locked or not. Objects can not be added or edited on locked versions. [default to false]
number Option<i32> The number of this version.
staging Option<bool> Unused at this time. [default to false]
testing Option<bool> Unused at this time. [default to false]

Return type

crate::models::VersionResponse

Authorization

token

HTTP request headers

  • Content-Type: application/x-www-form-urlencoded
  • Accept: application/json

[Back to top] [Back to API list] [Back to README]

validate_service_version

Validate the version for a particular service and version.

let cfg = &Configuration::default();
let params = ValidateServiceVersionParams {
    // parameters
};
validate_service_version(cfg, params)

Parameters

Name Type Description Required Notes
service_id String Alphanumeric string identifying the service. [required]
version_id i32 Integer identifying a service version. [required]

Return type

crate::models::InlineResponse200

Authorization

token

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to README]