# welcome

A robust platform for developing, deploying, and running applications.

## Technical Requirements

### Assembly Attribute: `VisibleToskailPlatform`

For the skail platform to locate and execute methods decorated with `[skailFunction]` and `[skailCommand]`, you **must** declare the attribute below at the top of your `Program.cs`:

```csharp
using skail.Platform.Runtime.Configuration.Attributes;

[assembly: VisibleToskailPlatform]
```

This attribute is essential to expose functions to the platform runtime. Without it, the execution system cannot find your functions.

## Platform Environment Variables

Workload execution can be influenced by several environment variables used internally by the skail Platform runtime. They can be set in the platform UI (environments) or locally/CLI.

```json
"environmentVariables": {
  "SKAIL_MAX_PARALLEL_TASKS": "10",
  "IMAGE": "imagename:v1.0.138",
  "SIDECAR": "https://xxxx",
  "NAMESPACE": "xxxxxx",
  "SKAIL_KEY": "xxxx"
}
```

### Notes

* `SKAIL_MAX_PARALLEL_TASKS`: sets the degree of task-processing parallelism.
* `IMAGE`: runtime image version.
* `SIDECAR`: internal API URL used by the platform sidecar.
* `SKAIL_KEY`: application identifier in the cluster.

Avoid changes without understanding the impact. When in doubt, contact us.

***

## Quickstart Guide for .Net applications

### Prerequisites

* .NET 8.0+ installed
* Visual Studio or VS Code
* skail Platform account

### In 10 Minutes

{% stepper %}
{% step %}

### Install the template

```bash
dotnet new install skail.Templates.Project
```

{% endstep %}

{% step %}

### Create a new project

```bash
dotnet new skail-app -n MinhaPrimeiraApp
cd MinhaPrimeiraApp
```

{% endstep %}

{% step %}

### Run locally

```bash
dotnet run
```

{% endstep %}

{% step %}

### Publish to GitHub

```bash
git init
git add .
git commit -m "Initial commit"
git push origin main
```

{% endstep %}

{% step %}

### Configure in the platform

* Go to [app.skailhq.com](https://app.skailhq.com/)
* Create a new project
* Connect your repository
* Configure the workload
* Automatic deploy started!
  {% endstep %}
  {% endstepper %}

***

## Installation

{% stepper %}
{% step %}

### Install the NuGet Template

Install the official skail Platform template:

```bash
# Install template
dotnet new install skail.Templates.Project

# Verify installation
dotnet new list | grep skail
```

{% endstep %}

{% step %}

### Create the Project

```bash
# Create new project
dotnet new skail-app -n MinhaAplicacao

# Navigate to the directory
cd MinhaAplicacao

# Restore dependencies
dotnet restore
```

{% endstep %}

{% step %}

### Project Structure

After creation, you’ll see:

```
MinhaAplicacao/
├── Prog
```

{% endstep %}
{% endstepper %}
