# Initial Setup

Before setting up LP on your projects, please first create your program and download the latest dll files which can be found here: <https://licensepoint.net/download/Class_Library.zip> and add reference both dll on your project.

{% hint style="info" %}
You will need to have your program token, the latest LP dll and variable key at hand
{% endhint %}

```csharp
static class Program
    {
        /// <summary>
        /// The main entry point for the application.
        /// </summary>
        [STAThread]
        static void Main()
        {
            Api.LpiAuth.Secret = "Your Application Secret Key"; //Sets your program secret throughout the program
            Api.LpiAuth.Initialize("Application Version"); //Carries out auto-update and grabs program variables
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            Application.Run(new Form1());
        }
    }
```

**On the form that shows after login add this:**&#x20;

```csharp
 public Form2()
        {
            InitializeComponent();

            if (!ProgramVariables.Freemode)
            { 
                Security.ChallengeCheck(); //Checks if the user has logged in, passed the initialize method and hasn't triggered any security alarms
            }
        }
```

**Server Response:**

```csharp
UserInfo.Username = username
UserInfo.Email = email
UserInfo.Level = level
UserInfo.Expires = expires
UserInfo.IP = ip
ProgramVariables.Version
ProgramVariables.ProgramName

```


---

# 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://phpfreakbd.gitbook.io/licensepoint-lp-documentation/dll-class-documentations/initial-setup.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.
