# How to implement your own custom activation server?
Using the `arcana-base-server` utility, you only have to write a struct and
three functions.
The struct is the state of the activation regarding a host. This struct should
be able to parse a uri (passed as an `url::Url` instance) to have enough
information to connect to the targeted host.
For example, please look at the `arcana-nixos-server/src/host.rs` file.
The three functions consists of handler of the requests coming from the arcana
client:
* `apply_function` is the function which takes apply requests and process it.
* `build_function` is the function which takes build requests and process it.
* `copy_closure_function` is the function which takes copy closure requests and
process it.
Signatures of the function should be:
```rust
pub async fn apply(
target: TargetHost,
tx: tokio::sync::mpsc::Sender<Result<ApplyResponse, Status>>,
request: ApplyRequest,
) -> std::io::Result<()>;
pub async fn build(
target: TargetHost,
tx: tokio::sync::mpsc::Sender<Result<BuildResponse, Status>>,
request: BuildRequest,
) -> std::io::Result<()>;
pub async fn copy_closure(
target: TargetHost,
tx: tokio::sync::mpsc::Sender<Result<CopyClosureResponse, Status>>,
request: CopyClosureRequest,
) -> std::io::Result<()>;
```
where `TargetHost` is your struct defined earlier.
Functions takes the state and the request and push responses inside the `tx`
channel.
For more example, please take a look to the `arcana-nixos-server`.