urbit / NEAR

Public repo for Urbit Labs projects
MIT License
4 stars 3 forks source link

First pass at %near-handler gall agent #2

Closed humanizersequel closed 7 months ago

humanizersequel commented 8 months ago

Gall agent that interfaces with our fork of the Near Social VM. The initial target is supporting methods that add and remove a list of accounts

EDIT - Updated Issue:

%near-handler implements a %poke action that the frontend can poke to forward a poke to another agent.

[%poke agent=@tas mark=@tas data=???]

The hard part here is getting the type conversions right. What is the best way of converting the incoming frontend JSON to the action type for the receiving agent?

Demo: an Urbit app that, upon opening, simply displays a blank page and prints a message in dojo (or adds a pal, or something else trivial) via %near-handler.

liam-fitzgerald commented 8 months ago

Specification for gall agent

+$  acc  @uxH
+$  action
  $%  [%add =acc]
      [%del =acc]
  ==
+$  state-0  [%0 accs=(set acc)]
::  on-peek -> /x/accs  -> (set acc)
::  should %give %fact of %action as well
hanfel-dovned commented 8 months ago