# LINE Sign-in configuration

Use this when you want to enable the **LINE** button in an enrolment form.

Start with [Social sign-in](https://docs.thewalletcrew.io/enroll/enrolment-form/social-sign-in) to understand the user flow. Then come back here for the provider setup.

<div data-with-frame="true"><figure><img src="https://3566051324-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FWLc8AHXW4tdrAXUBfrYF%2Fuploads%2F2zgEJTB3p8hutlGFAfJo%2FLine-Social-Sign-In.png?alt=media&#x26;token=4d9d9e75-a2b2-44ae-9c74-9c796bb60dad" alt="Line-Social-Sign-In-Example" width="375"><figcaption><p>Connect with Line in an enrolment form example</p></figcaption></figure></div>

### Overview

#### What you'll set up

* A **Line Channem** with the Line Login product enabled.
* **Allowed OAuth redirect URIs** and **valid domains** for your enrolment form.
* The App ID stored in **The Wallet Crew** admin console.

#### Prerequisites

* Access to your **LINE Developers Console**.
* Permission to create and manage **channels**.
* The list of domains where your enrolment forms will run (prod + staging + dev + custom).

### Create the LINE channel

{% stepper %}
{% step %}

#### **Create a provider and channel**

Go to the LINE Developers Console

<p align="center"><a href="https://developers.line.biz/console" class="button secondary" data-icon="chevrons-right">Line Developer Console</a></p>

1. Select or create a **Provider**
2. Click **Create a new channel**
   {% endstep %}

{% step %}

#### **Select LINE Login**

![Select LINE Login](https://3566051324-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FWLc8AHXW4tdrAXUBfrYF%2Fuploads%2Fgit-blob-4c6a20decc2afea399a53a33796350744e8a6ea5%2Fline_sign_in_configuration_2.png?alt=media)

1. Choose **LINE Login**
2. Select app type: **Web app**
3. Fill the required information
4. Create the channel
   {% endstep %}

{% step %}

#### **Enable Email permission (OpenID Connect)**

Open your channel settings:

![Enable Email permission (OpenID Connect)](https://3566051324-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FWLc8AHXW4tdrAXUBfrYF%2Fuploads%2Fgit-blob-3443f7471b61c38a98e67aebfca84e67987dcb28%2Fline_sign_in_configuration_3.png?alt=media)

1. Go to the **OpenID Connect** section
2. Enable **Email address permission**

This step is required if your enrolment flow depends on email.
{% endstep %}

{% step %}

#### **Configure callback URLs**

In the **LINE Login** tab:

Add a callback URL for each environment:

```http
https://app.neostore.cloud/auth/callback/line
https://app-qa.neostore.cloud/auth/callback/line
https://app-dev.neostore.cloud/auth/callback/line
https://<your-custom-domain>/auth/callback/line
```

Important:

* The full URL must match exactly
* Include `/auth/callback/line`
* Add prod + QA + dev + custom domains

Save your changes.
{% endstep %}

{% step %}

### Publish your channel

In the top-left corner, click **Developing**.

<figure><img src="https://3566051324-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FWLc8AHXW4tdrAXUBfrYF%2Fuploads%2F83VRWP29BCYMDaoFyTSJ%2Fimage.png?alt=media&#x26;token=1d7a51ec-a4ff-425d-b0f6-b567302dc90f" alt=""><figcaption></figcaption></figure>

Then click **Publish** to make the channel available for production use.
{% endstep %}
{% endstepper %}

### Configure LINE in The Wallet Crew

In The Wallet Crew Backoffice, open the LINE configuration page.

<p align="center"><a href="https://admin.thewalletcrew.io/tenant/~/settings/social/line" class="button secondary" data-icon="chevrons-right">Social Login -> Line</a></p>

<div data-with-frame="true"><figure><img src="https://3566051324-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FWLc8AHXW4tdrAXUBfrYF%2Fuploads%2FUNubAgYWXuUK2fXItW8o%2Fimage.png?alt=media&#x26;token=43707f99-827f-41f7-8b92-697cb32fe01b" alt="The Wallet Crew - Line configuration screen" width="563"><figcaption><p>Line configuration screen</p></figcaption></figure></div>

Copy the values from the LINE Developers Console into The Wallet Crew.

After saving, keep this page open for a quick cross-check:

* The LINE channel must be the same one used for the callback URLs.
* The saved `clientId` must match the **Channel ID** exactly.

{% hint style="info" %}
You can find these values in:

LINE Developers Console → Your channel → **Basic settings**
{% endhint %}

### Enable LINE on your enrolment form

Enable the provider in the enrolment form settings.

Go into `advanced configuration -> Layout`. Open the layout to activate social sign-in on and add these lines:

<pre class="language-yaml"><code class="lang-yaml"><strong>signinOptions:
</strong>  providers:
    - type: line
</code></pre>

For more information see [Enrolment form](https://docs.thewalletcrew.io/enroll/enrolment-form).

### FAQ

<details>

<summary>Which LINE channel type should I create for this setup?</summary>

Create a **LINE Login** channel with app type **Web app**.

That’s the channel type that supports the OAuth callback flow used by enrolment forms.

</details>

<details>

<summary>Do I need to enable “Email address permission” in OpenID Connect?</summary>

Enable it if your enrolment flow requires an email.

Without it, LINE may not return an email for the user.

</details>

<details>

<summary>What callback URLs do I need to add?</summary>

Add one callback URL per environment.

The URL must match exactly and must include `/auth/callback/line`.

Use the patterns listed above for prod, QA, dev, and any custom domain.

</details>

<details>

<summary>Where do I find the LINE <code>clientId</code> ?</summary>

In the LINE Developers Console:

**Your channel → Basic settings**.

Copy the **Channel ID** into `authentication.clientId`.

</details>

<details>

<summary>How do I actually show the LINE button on the enrolment form?</summary>

Enable the provider in your **enrolment form settings**.

If you manage buttons via layout YAML, add `- type: line` under `signinOptions.providers`.

</details>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.thewalletcrew.io/enroll/enrolment-form/social-sign-in/line-sign-in.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
