# ResourceApi > [!NOTE] > All URIs are relative to `https://api.fastly.com` Method | HTTP request | Description ------ | ------------ | ----------- [**create_resource**](ResourceApi.md#create_resource) | **POST** /service/{service_id}/version/{version_id}/resource | Create a resource link [**delete_resource**](ResourceApi.md#delete_resource) | **DELETE** /service/{service_id}/version/{version_id}/resource/{id} | Delete a resource link [**get_resource**](ResourceApi.md#get_resource) | **GET** /service/{service_id}/version/{version_id}/resource/{id} | Display a resource link [**list_resources**](ResourceApi.md#list_resources) | **GET** /service/{service_id}/version/{version_id}/resource | List resource links [**update_resource**](ResourceApi.md#update_resource) | **PUT** /service/{service_id}/version/{version_id}/resource/{id} | Update a resource link ## create_resource Create a link between a resource and a service version. ```rust let cfg = &Configuration::default(); let params = CreateResourceParams { // parameters }; create_resource(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] | **resource_id** | Option\<**String**> | The ID of the underlying linked resource. | | **name** | Option\<**String**> | The name of the resource link. | | ### Return type [**crate::models::ResourceResponse**](ResourceResponse.md) ### Authorization [token](../README.md#token) ### HTTP request headers - **Content-Type**: application/x-www-form-urlencoded - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) ## delete_resource Delete a link between a resource and a service version. ```rust let cfg = &Configuration::default(); let params = DeleteResourceParams { // parameters }; delete_resource(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] | **id** | **String** | An alphanumeric string identifying the resource link. | [required] | ### Return type [**crate::models::InlineResponse200**](InlineResponse200.md) ### Authorization [token](../README.md#token) ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) ## get_resource Display a resource link by its identifier. ```rust let cfg = &Configuration::default(); let params = GetResourceParams { // parameters }; get_resource(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] | **id** | **String** | An alphanumeric string identifying the resource link. | [required] | ### Return type [**crate::models::ResourceResponse**](ResourceResponse.md) ### Authorization [token](../README.md#token) ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) ## list_resources List links between resources and services ```rust let cfg = &Configuration::default(); let params = ListResourcesParams { // parameters }; list_resources(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 [**Vec<crate::models::ResourceResponse>**](ResourceResponse.md) ### Authorization [token](../README.md#token) ### HTTP request headers - **Content-Type**: Not defined - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) ## update_resource Update a link between a resource and a service version. ```rust let cfg = &Configuration::default(); let params = UpdateResourceParams { // parameters }; update_resource(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] | **id** | **String** | An alphanumeric string identifying the resource link. | [required] | **resource_id** | Option\<**String**> | The ID of the underlying linked resource. | | **name** | Option\<**String**> | The name of the resource link. | | ### Return type [**crate::models::ResourceResponse**](ResourceResponse.md) ### Authorization [token](../README.md#token) ### HTTP request headers - **Content-Type**: application/x-www-form-urlencoded - **Accept**: application/json [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)