You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
when I try to download a google drive file through the sdk like this:
const apideck = new Apideck({
apiKey: process.env.API_DECK_API_KEY!,
appId: process.env.API_DECK_APP_ID!,
consumerId: consumerId,
});
let data = null;
try {
data = await apideck.fileStorage.filesDownload({
id: fileId,
consumerId,
appId: process.env.API_DECK_APP_ID,
serviceId: 'google-drive',
});
console.log('API called successfully', data);
} catch (error) {
console.error('Error: ', error);
}
same error through the api calling it like this:
await fetch(https://unify.apideck.com/file-storage/files/${fileId}/download, {
method: 'GET',
headers: {
'x-apideck-consumer-id': consumerId,
'x-apideck-app-id': process.env.API_DECK_APP_ID!,
Authorization: Bearer ${process.env.API_DECK_API_KEY!},
},
});
The text was updated successfully, but these errors were encountered:
I get this error:
Response {
[🚀exprs] size: 0,
[🚀exprs] [Symbol(Body internals)]: {
[🚀exprs] body: PassThrough {
[🚀exprs] _readableState: [ReadableState],
[🚀exprs] _events: [Object: null prototype],
[🚀exprs] _eventsCount: 5,
[🚀exprs] _maxListeners: undefined,
[🚀exprs] _writableState: [WritableState],
[🚀exprs] allowHalfOpen: true,
[🚀exprs] [Symbol(kCapture)]: false,
[🚀exprs] [Symbol(kCallback)]: null
[🚀exprs] },
[🚀exprs] stream: PassThrough {
[🚀exprs] _readableState: [ReadableState],
[🚀exprs] _events: [Object: null prototype],
[🚀exprs] _eventsCount: 5,
[🚀exprs] _maxListeners: undefined,
[🚀exprs] _writableState: [WritableState],
[🚀exprs] allowHalfOpen: true,
[🚀exprs] [Symbol(kCapture)]: false,
[🚀exprs] [Symbol(kCallback)]: null
[🚀exprs] },
[🚀exprs] boundary: null,
[🚀exprs] disturbed: false,
[🚀exprs] error: null
[🚀exprs] },
[🚀exprs] [Symbol(Response internals)]: {
[🚀exprs] type: 'default',
[🚀exprs] url: 'https://unify.apideck.com/file-storage/files/${fileId}/download',
[🚀exprs] status: 401,
[🚀exprs] statusText: 'Unauthorized',
[🚀exprs] headers: {
[🚀exprs] 'access-control-allow-credentials': 'true',
[🚀exprs] 'access-control-allow-origin': '*',
[🚀exprs] connection: 'close',
[🚀exprs] 'content-length': '322',
[🚀exprs] 'content-type': 'application/json',
[🚀exprs] date: 'Tue, 27 Jun 2023 13:06:13 GMT',
[🚀exprs] via: '1.1 c3f257ad7ec4633c503cd21a690fa4dc.cloudfront.net (CloudFront)',
[🚀exprs] 'x-amz-apigw-id': 'HLe-0HeHFiAFW2g=',
[🚀exprs] 'x-amz-cf-id': 'lp7J8MVXqXl58FiiTU3ewZbdJUkNm0TbwfExfq8KCNigrEHloMGaKw==',
[🚀exprs] 'x-amz-cf-pop': 'MIA3-C2',
[🚀exprs] 'x-amzn-requestid': 'dd57c3cf-d405-4cb2-b2f2-8ed6b60aece2',
[🚀exprs] 'x-amzn-trace-id': 'Root=1-649adec4-275a46b20ded46df2a8114a2',
[🚀exprs] 'x-cache': 'Error from cloudfront'
[🚀exprs] },
[🚀exprs] counter: 0,
[🚀exprs] highWaterMark: 10000000
[🚀exprs] }
[🚀exprs] }
when I try to download a google drive file through the sdk like this:
const apideck = new Apideck({
apiKey: process.env.API_DECK_API_KEY!,
appId: process.env.API_DECK_APP_ID!,
consumerId: consumerId,
});
let data = null;
try {
data = await apideck.fileStorage.filesDownload({
id: fileId,
consumerId,
appId: process.env.API_DECK_APP_ID,
serviceId: 'google-drive',
});
console.log('API called successfully', data);
} catch (error) {
console.error('Error: ', error);
}
same error through the api calling it like this:
await fetch(
https://unify.apideck.com/file-storage/files/${fileId}/download
, {method: 'GET',
headers: {
'x-apideck-consumer-id': consumerId,
'x-apideck-app-id': process.env.API_DECK_APP_ID!,
Authorization:
Bearer ${process.env.API_DECK_API_KEY!}
,},
});
The text was updated successfully, but these errors were encountered: