> For clean Markdown of any page, append .md to the page URL. > For a complete documentation index, see https://developer.staging.frame.io/platform/v4/api-reference/shares/add-asset/llms.txt. > For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://developer.staging.frame.io/_mcp/server. # Add new asset to share POST https://api.frame.io/v4/accounts/{account_id}/shares/{share_id}/assets Content-Type: application/json Add new asset share. Rate Limits: 10 calls per 1.00 minute(s) per account\_user Reference: https://developer.staging.frame.io/platform/api-reference/shares/add-asset ## Authentication - `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer `, where token is your auth token. ## Request ### Path parameters - `account_id` (string, required) - `share_id` (string, required) ### Body (application/json) This endpoint expects an AddAssetParams. - `data` (AddAssetParamsData, required) ## Response ### 200 OK - `data` (AddAssetResponseData, required) ## Errors ### 400 Bad Request Error Bad Request - `errors` (list of BadRequestErrorsItems, required) ### 401 Unauthorized Error Unauthorized - `errors` (list of UnauthorizedErrorsItems, required) ### 403 Forbidden Error Forbidden - `errors` (list of ForbiddenErrorsItems, required) ### 404 Not Found Error Not Found - `errors` (list of NotFoundErrorsItems, required) ### 422 Unprocessable Entity Error Unprocessable Entity - `errors` (list of UnprocessableEntityErrorsItems, required) ### 429 Too Many Requests Error Too Many Requests - `errors` (list of TooManyRequestsErrorsItems, required) ## Types ### AddAssetParamsData - `asset_id` (string, required) — ID for asset to be added ### AddAssetResponseData - `access` (enum, required) - Allowed values: `public`, `secure` - `asset_added` (string, required) — ID for asset added - `collection_id` (string, required) — Collection ID - `commenting_enabled` (boolean, required) - `created_at` (string, required) — Creation timestamp - `description` (string, required, nullable) — Share description - `downloading_enabled` (boolean, required) - `enabled` (boolean, required) - `expiration` (string, required, nullable) — Expiration timestamp - `id` (string, required) — Share ID - `last_viewed_at` (string, required, nullable) — Last viewed timestamp - `name` (string, required, nullable) — Share name - `short_url` (string, required, nullable) — Share URL - `updated_at` (string, required) — Update timestamp - `passphrase` (string, optional, nullable) — Passphrase to access share, if passphrase is required and not given it will be generated ### BadRequestErrorsItems - `detail` (string, required) - `source` (BadRequestErrorsItemsSource, optional) - `title` (string, optional) ### UnauthorizedErrorsItems - `detail` (string, required) - `source` (UnauthorizedErrorsItemsSource, optional) - `title` (string, optional) ### ForbiddenErrorsItems - `detail` (string, required) - `source` (ForbiddenErrorsItemsSource, optional) - `title` (string, optional) ### NotFoundErrorsItems - `detail` (string, required) - `source` (NotFoundErrorsItemsSource, optional) - `title` (string, optional) ### UnprocessableEntityErrorsItems - `detail` (string, required) - `source` (UnprocessableEntityErrorsItemsSource, optional) - `title` (string, optional) ### TooManyRequestsErrorsItems - `detail` (string, required) - `source` (TooManyRequestsErrorsItemsSource, optional) - `title` (string, optional) ### BadRequestErrorsItemsSource - `pointer` (string, optional) ### UnauthorizedErrorsItemsSource - `pointer` (string, optional) ### ForbiddenErrorsItemsSource - `pointer` (string, optional) ### NotFoundErrorsItemsSource - `pointer` (string, optional) ### UnprocessableEntityErrorsItemsSource - `pointer` (string, optional) ### TooManyRequestsErrorsItemsSource - `pointer` (string, optional) ## Examples **Request** ```json { "data": { "asset_id": "6b0c7c60-979f-4a96-a824-889db8f9ff8c" } } ``` **Response** ```json { "data": { "access": "public", "asset_added": "257b251a-ffce-4c5c-b3e2-c3c77e1df0b9", "collection_id": "b3252929-2bd2-4b7b-9db2-7e7e8f798284", "commenting_enabled": true, "created_at": "2024-02-02T21:19:24.828948Z", "description": "Description of share", "downloading_enabled": true, "enabled": true, "expiration": "2025-10-24T22:42:23.690532Z", "id": "e92216a0-4497-4980-9f35-4c480a926139", "last_viewed_at": "2024-03-02T21:19:24.828948Z", "name": "Test Share", "short_url": "https://f.io/GGa9wPw5", "updated_at": "2024-02-02T21:19:24.828948Z", "passphrase": "as!dfj39sd(*" } } ``` **SDK Code** ```python import requests url = "https://api.frame.io/v4/accounts/fc8af01b-f9c3-4a1a-b365-8839f95f0bcf/shares/1cb4f0ca-1358-4bcc-ab34-2aefe6cbd257/assets" payload = { "data": { "asset_id": "6b0c7c60-979f-4a96-a824-889db8f9ff8c" } } headers = { "Authorization": "Bearer ", "Content-Type": "application/json" } response = requests.post(url, json=payload, headers=headers) print(response.json()) ``` ```javascript const url = 'https://api.frame.io/v4/accounts/fc8af01b-f9c3-4a1a-b365-8839f95f0bcf/shares/1cb4f0ca-1358-4bcc-ab34-2aefe6cbd257/assets'; const options = { method: 'POST', headers: {Authorization: 'Bearer ', 'Content-Type': 'application/json'}, body: '{"data":{"asset_id":"6b0c7c60-979f-4a96-a824-889db8f9ff8c"}}' }; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api.frame.io/v4/accounts/fc8af01b-f9c3-4a1a-b365-8839f95f0bcf/shares/1cb4f0ca-1358-4bcc-ab34-2aefe6cbd257/assets" payload := strings.NewReader("{\n \"data\": {\n \"asset_id\": \"6b0c7c60-979f-4a96-a824-889db8f9ff8c\"\n }\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("Authorization", "Bearer ") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api.frame.io/v4/accounts/fc8af01b-f9c3-4a1a-b365-8839f95f0bcf/shares/1cb4f0ca-1358-4bcc-ab34-2aefe6cbd257/assets") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["Authorization"] = 'Bearer ' request["Content-Type"] = 'application/json' request.body = "{\n \"data\": {\n \"asset_id\": \"6b0c7c60-979f-4a96-a824-889db8f9ff8c\"\n }\n}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api.frame.io/v4/accounts/fc8af01b-f9c3-4a1a-b365-8839f95f0bcf/shares/1cb4f0ca-1358-4bcc-ab34-2aefe6cbd257/assets") .header("Authorization", "Bearer ") .header("Content-Type", "application/json") .body("{\n \"data\": {\n \"asset_id\": \"6b0c7c60-979f-4a96-a824-889db8f9ff8c\"\n }\n}") .asString(); ``` ```php request('POST', 'https://api.frame.io/v4/accounts/fc8af01b-f9c3-4a1a-b365-8839f95f0bcf/shares/1cb4f0ca-1358-4bcc-ab34-2aefe6cbd257/assets', [ 'body' => '{ "data": { "asset_id": "6b0c7c60-979f-4a96-a824-889db8f9ff8c" } }', 'headers' => [ 'Authorization' => 'Bearer ', 'Content-Type' => 'application/json', ], ]); echo $response->getBody(); ``` ```csharp using RestSharp; var client = new RestClient("https://api.frame.io/v4/accounts/fc8af01b-f9c3-4a1a-b365-8839f95f0bcf/shares/1cb4f0ca-1358-4bcc-ab34-2aefe6cbd257/assets"); var request = new RestRequest(Method.POST); request.AddHeader("Authorization", "Bearer "); request.AddHeader("Content-Type", "application/json"); request.AddParameter("application/json", "{\n \"data\": {\n \"asset_id\": \"6b0c7c60-979f-4a96-a824-889db8f9ff8c\"\n }\n}", ParameterType.RequestBody); IRestResponse response = client.Execute(request); ``` ```swift import Foundation let headers = [ "Authorization": "Bearer ", "Content-Type": "application/json" ] let parameters = ["data": ["asset_id": "6b0c7c60-979f-4a96-a824-889db8f9ff8c"]] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api.frame.io/v4/accounts/fc8af01b-f9c3-4a1a-b365-8839f95f0bcf/shares/1cb4f0ca-1358-4bcc-ab34-2aefe6cbd257/assets")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```