The Fluence Labs Developer Hub

Welcome to the Fluence Labs developer hub. You'll find comprehensive guides and documentation to help you start working with Fluence Labs as quickly as possible, as well as support if you get stuck. Let's jump right in!

Should you have any questions, feel free to join our Discord or Telegram!

Get Started


Grasp and use


The most basic pattern you can find in AIR scripts is sending particles to clients via a relay.

It looks like in the example below:

    (call relay  ("op" "identity") [])
    (call client ("service" "function") [arg])

Here, client is a variable with the value of the client PeerId, and relay is equal to the PeerId of the node which the client is connected to. The following picture might explain the situation better.

Client is behind NAT and has to maintain connection with relay to receive particles

So, for the particle to reach the client behind the relay, the script must explicitly specify this network topology as follows:

  • Go to the relay, do nothing (op identity).
  • Go to the client, execute the required function.

Service creation


Updated about a month ago


Grasp and use

Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.