curl --request GET \
--url https://api.fabric.inc/v3/product-files/actions/download \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.fabric.inc/v3/product-files/actions/download"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.fabric.inc/v3/product-files/actions/download', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.fabric.inc/v3/product-files/actions/download",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.fabric.inc/v3/product-files/actions/download"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.fabric.inc/v3/product-files/actions/download")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.fabric.inc/v3/product-files/actions/download")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"location": "https://pim-v3-dev02-us-east-1-files.s3.us-east-1.amazonaws.com/local/ITEM_VARIANT_EXPORT/abc.csv?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIARD6W3CJ53CEYXKIJ%252F20230317%252Fus-east-1%252Fs3%252Faws4_request&X-Amz-Date=20230317T171516Z&X-Amz-Expires=300&X-Amz-Signature=f7069f25d72ac10f2163a134550cd68658de7a23d9960dc61ebaa67c8f54eb77&X-Amz-SignedHeaders=host&x-id=GetObject"
}{
"message": "Request is invalid",
"type": "Bad request",
"errors": [
{
"type": "CLIENT_ERROR",
"message": "Invalid request. Unable to find/create product"
}
]
}{
"type": "UNAUTHORIZED_ERROR",
"message": "Requester is unauthorized"
}{
"type": "REQUEST_DENIED",
"message": "User doesn't have the required permission"
}{
"type": "NOT_FOUND",
"message": "Resource not found"
}{
"type": "SERVER_ERROR",
"message": "Internal Server Error"
}Download a File by ID
Use this endpoint to get a download link for imported file, which you can use to review or update the file . Note: The link is valid only for five minutes.
curl --request GET \
--url https://api.fabric.inc/v3/product-files/actions/download \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.fabric.inc/v3/product-files/actions/download"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.fabric.inc/v3/product-files/actions/download', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.fabric.inc/v3/product-files/actions/download",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.fabric.inc/v3/product-files/actions/download"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.fabric.inc/v3/product-files/actions/download")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.fabric.inc/v3/product-files/actions/download")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"location": "https://pim-v3-dev02-us-east-1-files.s3.us-east-1.amazonaws.com/local/ITEM_VARIANT_EXPORT/abc.csv?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIARD6W3CJ53CEYXKIJ%252F20230317%252Fus-east-1%252Fs3%252Faws4_request&X-Amz-Date=20230317T171516Z&X-Amz-Expires=300&X-Amz-Signature=f7069f25d72ac10f2163a134550cd68658de7a23d9960dc61ebaa67c8f54eb77&X-Amz-SignedHeaders=host&x-id=GetObject"
}{
"message": "Request is invalid",
"type": "Bad request",
"errors": [
{
"type": "CLIENT_ERROR",
"message": "Invalid request. Unable to find/create product"
}
]
}{
"type": "UNAUTHORIZED_ERROR",
"message": "Requester is unauthorized"
}{
"type": "REQUEST_DENIED",
"message": "User doesn't have the required permission"
}{
"type": "NOT_FOUND",
"message": "Resource not found"
}{
"type": "SERVER_ERROR",
"message": "Internal Server Error"
}Authorizations
S2S access token (JWT) from fabric Identity service (during login)
Headers
A header used by fabric to identify the tenant making the request. You must include tenant id in the authentication header for an API request to access any of fabric’s endpoints. You can retrieve the tenant id , which is also called account id, from Copilot. This header is required.
"517fa9dfd42d8b00g1o3k312"
Unique request ID
"263e731c-45c8-11ed-b878-0242ac120002"
Query Parameters
24-character system-generated file ID
Response
OK
File download response
File download URL
"https://pim-v3-dev02-us-east-1-files.s3.us-east-1.amazonaws.com/local/ITEM_VARIANT_EXPORT/abc.csv?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=AKIARD6W3CJ53CEYXKIJ%252F20230317%252Fus-east-1%252Fs3%252Faws4_request&X-Amz-Date=20230317T171516Z&X-Amz-Expires=300&X-Amz-Signature=f7069f25d72ac10f2163a134550cd68658de7a23d9960dc61ebaa67c8f54eb77&X-Amz-SignedHeaders=host&x-id=GetObject"
Was this page helpful?
