To start the process of enabling the Cloud Datastore API, install the gcloud command line tools on your machine by installing the Google Cloud SDK. Run gcloud auth login
to link an account that has access to modify the target project. After signing in, you should see a screen that looks something like this:
Back in your web console, go to "Datastore" under the "Storage" heading and select "Entities."
When you get to the page, press "Select Datastore Mode." If you have an instance of Library cloned locally, you should be able to fun the following from inside your terminal:
gcloud datastore indexes create PATH_TO_LIBRARY_INSTANCE/config/index.yaml --project YOUR_PROJECT_ID_HERE
If you don't want to clone Library locally, you can instead download only the datastore indexes configuration file:
curl https://raw.githubusercontent.com/nytimes/library/master/config/index.yaml
,
wget https://raw.githubusercontent.com/nytimes/library/master/config/index.yaml
, or any other data downloading service will work for this. You can also copy-paste the contents of the file on GitHub into a file locally. Then, run the following from inside your terminal:
gcloud datastore indexes create PATH_TO_INDEX.YAML_FILE/index.yaml --project YOUR_PROJECT_ID_HERE
To find your project ID, navigate to the "IAM & admin" menu and select "Settings". Copy the value in the "Project ID" box.
The next (and final) step before deploying your app is to create an OAuth client.