You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
which guides you through creating a project in the Google API Console,
29
-
enabling the API, and creating credentials.
24
+
These environment variables are required for your app to utilize OAuth 2.0. To get started using the Gmail API, you need to first use the [setup tool](https://console.developers.google.com/flows/enableapi?apiid=gmail&credential=client_key&pli=1), to register your application for the Gmail API in the Google API Console. The setup tool will guide you through creating a project in the Google API Console, enabling the API, and creating authentication credentials. The setup process is easy and consists of the following three basic steps:
30
25
31
-
1. From the Credentials page, click **Create credentials >
32
-
OAuth client ID** to create your OAuth 2.0 credentials or
33
-
**Create credentials > Service account key** to create a service account.
34
-
2. If you created an OAuth client ID, then select your application type.
35
-
3. Fill in the form and click **Create**.
26
+
1. On the Credentials page, click **My Project** and select the project you want to use.
27
+
2. If you plan to create an **OAuth client ID**, click on the **OAuth consent screen** tab at the top of the **Credentials** page and fill out the form. You will need it in step 5.
28
+
3. Click on the **Credentials** tab at the top of the **Credentials** page.
29
+
4. Click the **Create credentials** button. From the drop-down list, select **OAuth client ID** if you want to create OAuth 2.0 credentials or select **Service account key** to create a service account.
30
+
5. If you chose to create an **OAuth client ID**, select your application type (e.g. Web application, iOS app, etc.). Otherwise, go to step 6.
31
+
6. Fill out the form and click the **Create** button.
36
32
37
-
Your application's client IDs and service account keys are now listed on the Credentials page. For details, click a client ID; parameters vary depending on the ID type, but might include email address, client secret, JavaScript origins, or redirect URIs.
33
+
Your application's client IDs and service account keys are now listed on the **Credentials** page. You can click on the client ID to see the details for this account. Depending on the type of ID you created, you may see your email address, the client secret key, JavaScript origins, or the redirect URIs. Add the required information to your **GOOGLE_CLIENT_ID** and **GOOGLE_CLIENT_SECRET** environment variables.
38
34
39
35
#### PostgresSQL service
40
36
41
37
*`POSTGRES_HOST`
42
38
43
-
The hostname is installed in order to be able to integrate the
44
-
app with the database service.
39
+
Configure the **POSTGRES_HOST** environment variable to point to the host where you are running your PostgresSQL server. This is required to connect your application to the database.
45
40
46
41
*`POSTGRES_DB`
47
42
48
-
This environment variable need be used to define name for the database.
43
+
Add the name of your PostgreSQL database to the **POSTGRES_DB** environment variable. This lets the application know which database to connect to.
49
44
50
-
*`POSTGRES_USER`
45
+
*`POSTGRES_USER` & `POSTGRES_PASSWORD`
51
46
52
-
This environment variable is used in conjunction with
53
-
*POSTGRES_PASSWORD* to set a user and its password. This variable will
54
-
create the specified user with superuser power.
47
+
Set the **POSTGRES_USER** environment variable with the username you want to use to connect to the database. Set the **POSTGRES_PASSWORD** environment variable that user's password. Using environment variables to configure user authentication to your database is more secure than placing this configuration in your code. **NOTE:** The user you specify in these two environment variables should be a superuser, otherwise you will run into problems.
55
48
56
-
*`POSTGRES_PASSWORD`
49
+
#### Ethereum client service
57
50
58
-
This environment variable needs for you to use the PostgreSQL database.
59
-
This environment variable sets the superuser password for
60
-
PostgreSQL.
51
+
In order to begin working with the Ethereum blockchain you will need to install a client, such as [Parity](https://github.com/paritytech/parity) or [Geth](https://geth.ethereum.org/downloads/). Here is a brief description of the advantages of each:
61
52
62
-
#### Ethereum client service
53
+
##### Parity
54
+
* Written in Rust.
55
+
* Includes a pruning algorithm to prevent hard drive usage from growing exponentially.
56
+
* Includes an easy-to-use browser-based GUI.
57
+
* Implements passive-mode, which reduces the load on your CPU and network.
58
+
* Warp sync allows you to sync your node from scratch in a matter of hours, as opposed to days.
59
+
* Uses the Kovan test network to help you test your application.
60
+
* More feature-complete than Geth.
61
+
62
+
##### Geth
63
+
* Written in Go.
64
+
* Considered to be the reference implementation of Ethereum.
65
+
* Uses the Rinkeby test network to help you test your application.
63
66
64
-
In order to begin to work with Ethereum blockchain you need to install
65
-
client service on any work machine.
67
+
**NOTE:** Both Parity and Geth can be installed on macOS via Homebrew. Ubuntu users can install Parity via apt. Please check to see if binary packages are available for your OS.
66
68
67
69
*`INFURA_URL`
68
70
69
-
The INFURA_URL is address your work machine with port your client
70
-
service.
71
+
The INFURA_URL environment variable should be set to the IP address of your local machine and should include the port the service is running on. For example, `http://10.150.0.4:8545`
71
72
72
73
*`ETHEREUM_PRIVATE_KEY`
73
74
74
-
In order to use Ethereum blockchain you need to create **wallet**, where
75
-
the private key will be generated. The private key needs in order to
76
-
app can work on behalf of your wallet.
75
+
In order to use the Ethereum blockchain you need to create a **wallet**. A private key will be created as part of the wallet-creation process. You will need to include your private key in the **ETHEREUM_PRIVATE_KEY** environment variable in order for the system to be able to communicate with your wallet.
77
76
78
77
*`OPEN_TOKEN_ADDRESS`
79
78
80
-
Before working in the app you need to create **smart contract** in
81
-
Ethereum blockchain. After creating you get *OPEN_TOKEN_ADDRESS*.
82
-
With which app can check the transfers of clients.
79
+
Before working in the app you need to create a **smart contract** within Ethereum. After creating a **smart contract**, you will receive an **OPEN_TOKEN_ADDRESS**. You will need to set the **OPEN_TOKEN_ADDRESS** to include this token in order for the system to check client transfers.
0 commit comments