Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

Why ITCHIO_API_KEY is not ingested into my native app

A topic by Praytic created Dec 09, 2023 Views: 130
Viewing posts 1 to 1

I have a Godot application where I want to use itch.io identity for authentication. This is my code for retrieval of the environment variable:
```
_api_key = OS.get_environment("ITCHIO_API_KEY")
if _api_key.is_empty():
    push_error("Missing API key for itch.io identity provider.")
```

Here's my .itch.toml file, I have validated with butler:

```
[[actions]]
name = "identity-provisioning"
path = "YouTD2.app"
platform = "osx"
scope = "profile:me"

[[actions]]
name = "identity-provisioning"
path = "youtd2.exe"
platform = "windows"
scope = "profile:me"

[[actions]]
name = "identity-provisioning"
path = "youtd2.x86_64"
platform = "linux"
scope = "profile:me"

```

I have exported my project and placed this .itch.toml file near my .app file:

This configuration doesn't work for me, I see in logs the entry "Missing API key for itch.io identity provider." which means environment variable wasn't populated. How fix this issue? 

This topic has been auto-archived and can no longer be posted in because there haven't been any posts in a while.