# \[Archive\] Expected URL scheme 'http' or 'https' but no colon was found

**URL:** <https://builder.metamask.io/t/archive-expected-url-scheme-http-or-https-but-no-colon-was-found/1269>\
**Category:** Embedded Wallets (Web3Auth)\
**Created:** [August 15, 2024, 6:42pm UTC](https://builder.metamask.io/t/archive-expected-url-scheme-http-or-https-but-no-colon-was-found/1269 "2024-08-15T18:42:22Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![nethaji](https://avatars.discourse-cdn.com/v4/letter/n/5f9b8f/32.png) [@nethaji](https://builder.metamask.io/u/nethaji)\
**Post date:** [August 15, 2024, 6:42pm UTC](https://builder.metamask.io/t/archive-expected-url-scheme-http-or-https-but-no-colon-was-found/1269/1 "2024-08-15T18:42:22Z")

</div>

> **🏛 Archived Content from Web3Auth Community**
> 
> This topic was originally posted by **nethaji** on 8/15/2024.  
> This content has been migrated from our previous community forum to preserve valuable discussions.

* * *

There is an Exception throwed when trying to get keys using custom JWT with below function, and network is on SAPPHIRE\_DEVNET.

```auto
@RequiresApi(Build.VERSION_CODES.O)
    fun signIn(){
        try {
            val sub = "2cgkq"
            val idToken = "CUSTOM_JWT_TOKEN"
            loginParams = LoginParams("test-app", sub, idToken)
            torusKey = singleFactorAuth.getKey(
                loginParams,
                context,
                86400
            ).get()
            publicAddress = torusKey?.publicAddress.toString()
            Log.d("Web3Auth", """Private Key: ${torusKey?.privateKey?.toString(16)}""".trimIndent())
        } catch (e: ExecutionException) {
            Log.d("Web3Auth", e.message.toString())
        } catch (e: InterruptedException) {
            Log.d("Web3Auth", e.message.toString())
        }
    }

```

Exception:

```auto
java.util.concurrent.ExecutionException: java.lang.IllegalArgumentException: Expected URL scheme 'http' or 'https' but no colon was found

```

---

<div class="post-metadata">

**Author:** ![Ayush](https://yyz1.discourse-cdn.com/flex011/user_avatar/builder.metamask.io/ayush/32/1540_2.png) [@Ayush](https://builder.metamask.io/u/Ayush)\
**Post date:** [August 16, 2024, 2:50am UTC](https://builder.metamask.io/t/archive-expected-url-scheme-http-or-https-but-no-colon-was-found/1269/2 "2024-08-16T02:50:09Z")

</div>

Hey @nethaji can you share the Android SFA version you are using, also is this exception triggered when you are doing getKey?

---

<div class="post-metadata">

**Author:** ![nethaji](https://avatars.discourse-cdn.com/v4/letter/n/5f9b8f/32.png) [@nethaji](https://builder.metamask.io/u/nethaji)\
**Post date:** [August 16, 2024, 5:10am UTC](https://builder.metamask.io/t/archive-expected-url-scheme-http-or-https-but-no-colon-was-found/1269/3 "2024-08-16T05:10:08Z")

</div>

I’m using the following versions in my project:

```auto
implementation 'com.github.Web3auth:single-factor-auth-android:0.4.0'
implementation 'org.torusresearch:fetch-node-details-java:5.0.0'

```

And yes, I’m encountering an exception when I call `getKey`."

---

<div class="post-metadata">

**Author:** ![Ayush](https://yyz1.discourse-cdn.com/flex011/user_avatar/builder.metamask.io/ayush/32/1540_2.png) [@Ayush](https://builder.metamask.io/u/Ayush)\
**Post date:** [August 18, 2024, 5:08pm UTC](https://builder.metamask.io/t/archive-expected-url-scheme-http-or-https-but-no-colon-was-found/1269/4 "2024-08-18T17:08:11Z")

</div>

The error you are getting is more of HTTP url not being correct, not sure if it’s from Web3Auth. I’ll try our example. Can you get the stack trace for the error?

---

<div class="post-metadata">

**Author:** ![Ayush](https://yyz1.discourse-cdn.com/flex011/user_avatar/builder.metamask.io/ayush/32/1540_2.png) [@Ayush](https://builder.metamask.io/u/Ayush)\
**Post date:** [August 21, 2024, 11:40am UTC](https://builder.metamask.io/t/archive-expected-url-scheme-http-or-https-but-no-colon-was-found/1269/5 "2024-08-21T11:40:20Z")

</div>

Hey, I tried to reproduce the error. It’s working fine, can you please share the detail stack trace for the error?
