Economy API
Economy API is used to interact and manage the economy created on the Fuse Studio.

Add foreign token address to community

1
PUT /communities/:communityAddress/foreignToken
Copied!

Parameter Parameters

Name
Type
Description
communityAddress
String
Community address
foreignTokenAddress
foreignTokenAddress

Param Examples

json - Request-Example:
1
{
2
"foreignTokenAddress": {{foreignTokenAddress}}
3
}
Copied!

Add plugins to community

1
POST /communities/:communityAddress/plugins
Copied!

Parameter Parameters

Name
Type
Description
communityAddress
String
Community address
plugins
Object
The plugins (with arguments)

Param Examples

json - Request-Example:
1
{
2
"name": "joinBonus",
3
"isActive": false
4
}
Copied!

1
GET /communities/count
Copied!

Fetch community

Community is a set of contracts and services. Members of the community are users of the Fuse network. The community is configured via the plugins.
1
GET /communities/:communityAddress
Copied!

Parameter Parameters

Name
Type
Description
communityAddress
String
Community address

Success 200

Name
Type
Description
communityAddress
String
Address of the community on the Fuse network
homeTokenAddress
String
Address of the community token on the Fuse network
foreignTokenAddress
String
Address of the community token on the Ethereum network
homeBridgeAddress
String
Address of the community bridge on the Fuse network
foreignBridgeAddress
String
Address of the community bridge on the Ethereum network
isClosed
Boolean
Is the community is closed or open. Closed community requires an approve of community admin to join.
plugins
Object
Defines the community plugins.

Fetch community with plugins adjusted for the specified account

Community is a set of contracts and services. Members of the community are users of the Fuse network. The community is configured via the plugins.
1
GET /communities/:communityAddress
Copied!

Parameter Parameters

Name
Type
Description
communityAddress
String
Community address
accountAddress
String
User account address

Success 200

Name
Type
Description
communityAddress
String
Address of the community on the Fuse network
homeTokenAddress
String
Address of the community token on the Fuse network
foreignTokenAddress
String
Address of the community token on the Ethereum network
homeBridgeAddress
String
Address of the community bridge on the Fuse network
foreignBridgeAddress
String
Address of the community bridge on the Ethereum network
isClosed
Boolean
Is the community is closed or open. Closed community requires an approve of community admin to join.
plugins
Object
Defines the community plugins.

Invite a user to community

1
POST /communities/:communityAddress/invite
Copied!

Parameter Parameters

Name
Type
Description
communityAddress
String
Community address

Param Examples

json - Request-Example:
1
{
2
"phoneNumber": {{userPhoneNumber}},
3
}
Copied!
json - Request-Example:
1
{
2
"email": {{userEmail}},
3
}
Copied!

Set secondary token for the community

1
PUT /communities/:communityAddress/secondary
Copied!

Parameter Parameters

Name
Type
Description
secondaryTokenAddress
String
Address of the secondary token
networkType
String
Token's network type
tokenType
String
Token's network type

Param Examples

json - Request-Example:
1
{
2
"secondaryTokenAddress": "0xd6aab51d1343dcbee9b47e6fef8ba4469cf3dbde",
3
"networkType": "fuse",
4
"tokenType": "basic"
5
}
Copied!

Update community metadata

1
PUT /communities/:communityAddress
Copied!

Parameter Parameters

Name
Type
Description
communityAddress
String
Community address
community
Object
metadata to update

Param Examples

json - Request-Example:
1
{
2
"communityURI": "ipfs://hash",
3
}
Copied!