apiMaxLimit
untyped bigintValue
(50 <untyped> bigint)
apiMaxScan
untyped bigintValue
(2000 <untyped> bigint)
renderAPI
func(route string, q url.Values) stringrenderAPI serves JSON for the web app, under Render("api/..."): api/stats counts, escrow totals, council, paused api/campaigns?status=&tag=&page=&limit= newest first; status "all" or empty for every campaign api/campaign/<id> one campaign api/campaign/<id>/claims?status=&page=&limit= its claims, newest first api/campaign/<id>/claimant/<address> {"claim": an address's latest claim, or null} api/user/<address>?page=&limit= campaigns an address is involved in, with roles and their claim
- OID
- 047232…fbcd:3
renderAPI details
apiStats
func() string- OID
- 047232…fbcd:5
apiStats details
apiClaims
func(c *v0.Campaign, q url.Values) string- OID
- 047232…fbcd:6
apiClaims details
apiUser
func(addr .uverse.address, q url.Values) string- OID
- 047232…fbcd:7
apiUser details
campaignJSON
func(c *v0.Campaign, full bool) string- OID
- 047232…fbcd:8
campaignJSON details
claimJSON
func(cl *v0.Claim) string- OID
- 047232…fbcd:9
claimJSON details
denomFields
func(denom string, isGRC20 bool) []stringdenomFields describes how to display amounts of denom.
- OID
- 047232…fbcd:10
denomFields details
limitOf
func(q url.Values) int- OID
- 047232…fbcd:11
limitOf details
apiError
func(msg string) string- OID
- 047232…fbcd:12
apiError details
ClaimShareBps
untyped bigintValue
(500 <untyped> bigint)
maxDeadlineDays
untyped bigintValue
(365 <untyped> bigint)
campaigns
v0.Tree// padded id -> \*campaign.Campaign
- OID
- 047232…fbcd:14
campaigns details
lastID
uint64Value
0
byUser
v0.Tree// address -> \*avl.Tree(padded id -> struct{})
- OID
- 047232…fbcd:17
byUser details
statusCount
map[v0.Status]int- OID
- 047232…fbcd:19
statusCount details
escrowed
v0.Tree// denom key -> int64 currently held
- OID
- 047232…fbcd:21
escrowed details
council
*v0.Ownable- OID
- 047232…fbcd:77
council details
paused
boolValue
false
InitialCouncil
.uverse.addressValue
<gnolang.StringValue>
init.21
func()- OID
- 047232…fbcd:24
init.21 details
PostCampaign
func(title string, description string, link string, tags string, reviewers string, reward int64, slots int, deadlineDays int) uint64PostCampaign posts a campaign funded with the native coins sent along with the call, which must equal reward × slots. reviewers is a comma-separated address list (empty means the poster reviews alone); any one of them can approve a claim. deadlineDays closes the campaign to new claims after that many days (0: no deadline).
- OID
- 047232…fbcd:26
PostCampaign details
PostCampaignGRC20
func(tokenKey string, title string, description string, link string, tags string, reviewers string, reward int64, slots int, deadlineDays int) uint64PostCampaignGRC20 posts a campaign funded with a registered GRC20 token. The caller must first approve this realm's address for reward × slots on the token; this call pulls the funds into escrow.
- OID
- 047232…fbcd:27
PostCampaignGRC20 details
newCampaign
func(denom string, isGRC20 bool, title string, description string, link string, tags string, reviewers string, reward int64, slots int, deadlineDays int) *v0.Campaign- OID
- 047232…fbcd:28
newCampaign details
store
func(c *v0.Campaign) uint64- OID
- 047232…fbcd:29
store details
Claim
func(id uint64, proof string) intClaim asks to be paid for doing the task once. proof is a link to the work (the post, the PR, the page). It reserves a slot until a reviewer decides. Returns the claim number.
- OID
- 047232…fbcd:30
Claim details
ApproveClaim
func(id uint64, claim int)ApproveClaim pays a pending claim. Any reviewer of the campaign.
- OID
- 047232…fbcd:31
ApproveClaim details
RejectClaim
func(id uint64, claim int, reason string)RejectClaim turns down a pending claim and frees its slot. Any reviewer of the campaign.
- OID
- 047232…fbcd:32
RejectClaim details
Close
func(id uint64)Close stops new claims and refunds the free slots to the poster. The poster can close at any time; anyone can close after the deadline. Pending claims can still be approved or rejected afterwards.
- OID
- 047232…fbcd:33
Close details
Council
func() .uverse.address- OID
- 047232…fbcd:34
Council details
TransferCouncil
func(newCouncil .uverse.address)TransferCouncil hands the council seat to another address. Council only.
- OID
- 047232…fbcd:35
TransferCouncil details
SetPaused
func(p bool)SetPaused stops or resumes new campaigns. Existing campaigns, claims and payouts are never paused. Council only.
- OID
- 047232…fbcd:36
SetPaused details
Count
func() intCount is the number of campaigns ever posted.
- OID
- 047232…fbcd:37
Count details
CountByStatus
func(status string) intCountByStatus counts campaigns in a status ("open" or "closed").
- OID
- 047232…fbcd:38
CountByStatus details
Escrowed
func(denom string) int64Escrowed is the amount of denom (a native denom or a grc20reg key) held.
- OID
- 047232…fbcd:39
Escrowed details
IsPaused
func() boolIsPaused reports whether new campaigns are paused.
- OID
- 047232…fbcd:40
IsPaused details
settle
func(int, rlm .uverse.realm, c *v0.Campaign, payouts []v0.Payout, reviewer .uverse.address)- OID
- 047232…fbcd:41
settle details
transfer
func(int, rlm .uverse.realm, c *v0.Campaign, to .uverse.address, amount int64)- OID
- 047232…fbcd:42
transfer details
mustGet
func(id uint64) *v0.Campaign- OID
- 047232…fbcd:43
mustGet details
getCampaign
func(id uint64) *v0.Campaign- OID
- 047232…fbcd:44
getCampaign details
moved
func(c *v0.Campaign, before v0.Status)- OID
- 047232…fbcd:45
moved details
addEscrow
func(c *v0.Campaign, delta int64)- OID
- 047232…fbcd:46
addEscrow details
index
func(addr .uverse.address, id uint64)- OID
- 047232…fbcd:47
index details
assertNotPaused
func()- OID
- 047232…fbcd:48
assertNotPaused details
check
func(err .uverse.error)- OID
- 047232…fbcd:49
check details
emit
func(event string, c *v0.Campaign, kv []string)- OID
- 047232…fbcd:50
emit details
idKey
func(id uint64) string- OID
- 047232…fbcd:51
idKey details
clip
func(s string, n int) string- OID
- 047232…fbcd:52
clip details
realmPath
untyped stringValue
"gno.land/r/g1lnkytfqcjwllws63gvf0mv9yt04aswy4y9amhm/guildhall/campaigns"
realmURL
untyped stringValue
"/r/g1lnkytfqcjwllws63gvf0mv9yt04aswy4y9amhm/guildhall/campaigns"
repURL
untyped stringValue
"/r/g1lnkytfqcjwllws63gvf0mv9yt04aswy4y9amhm/guildhall/reputation"
pageSize
untyped bigintValue
(20 <untyped> bigint)
Render
func(path string) stringRender serves the campaigns: "" every campaign (?status=open|closed|all, ?tag=x, ?page=N) <id> a campaign and its claims (?claims=pending|approved|rejected|all, ?page=N) u/<address> campaigns an address posted, reviews or claimed post how to post a campaign
- OID
- 047232…fbcd:53
Render details
renderBoard
func(q url.Values) string- OID
- 047232…fbcd:55
renderBoard details
scan
func(status string, tag string, skip int, limit int) (list []*v0.Campaign, more bool)scan lists campaigns newest first, filtered by status ("", "all" or a status name) and tag.
- OID
- 047232…fbcd:56
scan details
renderCampaign
func(id uint64, q url.Values) string- OID
- 047232…fbcd:57
renderCampaign details
renderActions
func(c *v0.Campaign) stringrenderActions lists the transactions anyone might want to send, as gnoweb transaction links. The chain enforces who may call them.
- OID
- 047232…fbcd:58
renderActions details
renderUser
func(addr .uverse.address, page int) string- OID
- 047232…fbcd:59
renderUser details
renderPost
func() string- OID
- 047232…fbcd:60
renderPost details
claimStatus
func(cl *v0.Claim) string- OID
- 047232…fbcd:61
claimStatus details
roles
func(c *v0.Campaign, addr .uverse.address) []string- OID
- 047232…fbcd:62
roles details
hasTag
func(c *v0.Campaign, tag string) bool- OID
- 047232…fbcd:63
hasTag details
tagSuffix
func(c *v0.Campaign) string- OID
- 047232…fbcd:64
tagSuffix details
person
func(addr .uverse.address) string- OID
- 047232…fbcd:65
person details
linkOrText
func(s string) string- OID
- 047232…fbcd:66
linkOrText details
formatAmount
func(c *v0.Campaign, amount int64) string- OID
- 047232…fbcd:67
formatAmount details
symbolOf
func(denom string, isGRC20 bool) (string, int)- OID
- 047232…fbcd:68
symbolOf details
escrowSummary
func() string- OID
- 047232…fbcd:69
escrowSummary details
decimal
func(amount int64, decimals int) string- OID
- 047232…fbcd:70
decimal details
bps
func(v int64) string- OID
- 047232…fbcd:71
bps details
idStr
func(c *v0.Campaign) string- OID
- 047232…fbcd:72
idStr details
boardLink
func(status string, tag string, page int) string- OID
- 047232…fbcd:73
boardLink details
splitQuery
func(path string) (string, url.Values)- OID
- 047232…fbcd:74
splitQuery details
pageOf
func(q url.Values) int- OID
- 047232…fbcd:75
pageOf details
notFound
func() string- OID
- 047232…fbcd:76