Skip to content

HTTPie and Credentials

synedra-datastax edited this page Mar 13, 2021 · 10 revisions

⚒️ HTTPie and Credentials

You have a couple of options at this point. If you've already got Node and Python 3.3 installed on your system, you can do the exercises right on your local system, which gives you the ability to tweak them and play with them as you wish into the future. The GitPod option makes it possible to just start up a development environment with a single click and get right to the exercises. You'll get enough time to do either in the workshop.

Objectives In this step, we will:

  1. Set up IDE
  2. Set up credentials for httpie and @astrajs
  3. Verify Credentials with HTTPie

1. Setup IDE

IMPORTANT! Don't forget to save when making code changes in your IDE or you might not get expected results.

To code during the workshop you can either use your laptop or the Cloud-based IDE Gitpod with everything installed.

Choose ONE of the following (GitPod or Local):


GitPod

GitPod online IDE (recommended)

Here we explain the Gitpod way

Gitpod is a cloud based IDE based on Eclipse Theia very similar to VSCode. You need to authenticate with your Github account and GitPod will initialize your workspace, building the solution. To initialize your environment follow the instructions below.

✔ Open a new tab in your browser and paste in the following partial URL. Do not submit the page just yet.

📘 URL to copy

gitpod.io/#

Paste in Gitpod url

✔ Now, go to YOUR ExploringStargate repository and copy its URL.

Copy your repo

✔ Finally, paste your repo URL at the end of the gitpod URL combining the two and hit enter to submit the page.

Gitpod full url

Once started your page should look something like this.

Gitpod full url

Notice the blue cube. You may also see some messages about downloading images. It might take a minute for the environment to startup, but if you are seeing this you should be good to go. Move on to the next step.

Local install

Local IDE

Here we explain how to work locally

+ We assume people working locally are not beginners
+ They should be autonomous to install a development > environment.

Here are the tools you need:

✔ Clone your BattleStax repository to localhost, use the following command in your terminal to do so:

📘 Command to execute

git clone git@github.com:[your_github_id]/battlestax.git

✔ Move to the proper directory

📘 Command to execute

cd battlestax

✔ Install Battlestax Dependencies. These are specified in the package.json file.

📘 Command to execute

npm install

2. Set Up Credentials

✅ Step 1a: Go back to the Astra UI and click the CONNECT button on the line for the database you just created.

This will bring you to the Connect page.

image