Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/makis-san/empire-inv-fetch-to-sheet
Get inventory value from CSGO EMPIRE and write on google sheet.
https://github.com/makis-san/empire-inv-fetch-to-sheet
csgoempire google-sheets-api nodejs
Last synced: about 1 month ago
JSON representation
Get inventory value from CSGO EMPIRE and write on google sheet.
- Host: GitHub
- URL: https://github.com/makis-san/empire-inv-fetch-to-sheet
- Owner: makis-san
- License: gpl-3.0
- Created: 2021-07-03T00:44:49.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-07-03T22:46:42.000Z (over 3 years ago)
- Last Synced: 2024-10-11T18:13:36.557Z (3 months ago)
- Topics: csgoempire, google-sheets-api, nodejs
- Language: TypeScript
- Homepage:
- Size: 32.2 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
# Fetch CSGOEmpire Deposit Inventory to Google Sheet
[![GitHub license](https://img.shields.io/github/license/makis-san/csgoempire-inventory-fetch-to-sheet)](https://github.com/makis-san/csgoempire-inventory-fetch-to-sheet/blob/main/LICENSE)
>I literally did this in 30 minutes and i'm actually planning to add more features. Please be patient 💙
## Dependencies
| package | dev | version |
| ------------ | --- | -------- |
| axios | ❌ | ^0.21.1 |
| dotenv | ❌ | ^10.0.0 |
| googleapis | ❌ | ^80.1.0 |
| @types/axios | ✔ | ^0.14.0 |
| @types/node | ✔ | ^15.14.0 |
| ts-node | ✔ | ^10.0.0 |
| ts-node | ✔ | ^4.3.5 |## How to use
1. **Get Empire Cookie**: Navigate to empire deposit page with google devtools, open Network tab and search for request from `https://csgoempire.com/api/v2/inventory/user?app=730`.
![](https://i.imgur.com/81ZnCp7.png)
![](https://i.imgur.com/m1AvhCs.png)
Head down on response headers and copy cookie header. This is your **EMPIRE_AUTH_COOKIE** enviroment variable.2. **Configure google api and google sheet.**
3. Have fun```shell
yarn && yarn start
```### Commandline Args
| key | value |
| --------- | -------------------------------------------------------------------------------- |
| -dev | enable console.log |
| -noGoogle | the application will only fetch data from csempire without updating google sheet |### Env
| key | value |
| ------------------------------ | --------------------------------------------- |
| GOOGLE_APPLICATION_CREDENTIALS | path to google api client credentials |
| SHEET_ID | google sheets id |
| PRICE_RANGE | range on sheet that stores the csempire price |
| TITLE_RANGE | range on sheet that stores item name |
| EMPIRE_AUTH_COOKIE | csempire user cookie |