1.0.17-beta • Published 3 months ago
internetarchive-sdk-js v1.0.17-beta
Internet Archive SDK for JavaScript
NodeJS / Typescript SDK for Internet Archive APIs
Internet Archive APIs
https://archive.org/services/docs/api/
Install
Use npm
to install the module
npm install internetarchive-sdk-js
Or use yarn
to install the module
yarn add internetarchive-sdk-js
Usage
Get Items
import InternetArchive from 'internetarchive-sdk-js'
const ia = new InternetArchive()
;(async () => {
const filters = {
collection: 'library_of_congress',
subject: 'basketball'
}
const options = {
rows: 10,
fields: 'identifier'
}
const items = await ia.getItems(filters, options)
console.log(items.response.docs)
})()
Update Item (Requires "S3-Like API Key")
import InternetArchive from 'internetarchive-sdk-js'
const { API_KEY } = process.env || {}
const ia = new InternetArchive(API_KEY, { testmode: true })
;(async () => {
const itemId = 'internetarchive-test-item-id'
try {
const response = await ia.updateItem(itemId, { title: 'new title' })
console.log(response)
} catch (error) {
console.log(error.response.data)
}
})()
1.0.16-beta
3 months ago
1.0.17-beta
3 months ago
1.0.15-beta
6 months ago
1.0.11-beta
11 months ago
1.0.12-beta
11 months ago
1.0.14-beta
11 months ago
1.0.13-beta
11 months ago
1.0.8-beta
2 years ago
1.0.10-beta
2 years ago
1.0.9-beta
2 years ago
1.0.7-beta
2 years ago
1.0.6-beta
2 years ago
1.0.5-beta
2 years ago
1.0.4-beta
2 years ago
1.0.3-beta
2 years ago
1.0.2-beta
2 years ago
1.0.1-beta
2 years ago
1.0.0-beta
2 years ago
1.0.0
2 years ago