Platform
Resources
Pricing
Sign in
Get started
Arturo Rebolledo
Economics students and Frontend Developer .
Workspace
Fork
Public
By
Arturo Rebolledo
Edited
Jan 16, 2024
ISC
Fork of
AWS S3 API Starter
1
Insert cell
Insert cell
region
=
"us-east-1"
Insert cell
bucket
=
"pinyin"
Insert cell
Insert cell
Inputs
.
table
(
contents
,
{
columns
:
[
"Key"
,
"LastModified"
,
"Owner"
,
"Size"
]
,
format
:
{
Owner
:
(
d
)
=>
d
.
DisplayName
,
Key
:
(
d
)
=>
html
`<a href="https://${
bucket
}.s3.amazonaws.com/${
d
}">${
d
}</a>`
}
}
)
Insert cell
// Either load the bucket contents or load the sample cached data
contents
=
client
?
(
await
client
.
send
(
new
AWS
.
ListObjectsCommand
(
{
Bucket
:
bucket
,
MaxKeys
:
100
}
)
)
)
.
Contents
:
FileAttachment
(
"contents.json"
)
.
json
(
)
Insert cell
Insert cell
AWS
=
import
(
"https://cdn.skypack.dev/@aws-sdk/client-s3@3.39.0"
)
Insert cell
client
=
{
try
{
return
new
AWS
.
S3Client
(
{
region
,
credentials
:
{
accessKeyId
:
Secret
(
"AWS_ACCESS_KEY_ID"
)
,
secretAccessKey
:
Secret
(
"AWS_SECRET_ACCESS_KEY"
)
}
}
)
}
catch
{
return
false
;
}
}
Insert cell
Insert cell
Insert cell
Purpose-built for displays of data
Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Try it for free
Learn more
Compare fork
Fork
View
Export
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
region
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
bucket
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
contents
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
Edit
Add comment
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
AWS
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
client
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
hasAccessKeyID
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML
hasSecretAccessKey
Edit
Add comment
Copy import
Select
Duplicate
Copy link
Embed
Delete
JavaScript
Markdown
HTML