Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
contentful で getEntry する簡単なサンプル
const contentful = require("contentful");
const client = contentful.createClient({
// This is the space ID. A space is like a project folder in Contentful terms
space: "ra794i9t0yln",
// This is the access token for this space. Normally you get both ID and the token in the Contentful web app
accessToken: "U1Wffn5NIhptGsWKyliQCILCWpoaCjJK6mwJwYO_58g"
// This API call will request an entry with the specified ID from the space defined at the top, using a space-specific access token.
.then((response) => console.log(response.items))
.then((entry) => console.log(entry))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment