enableTokenGatingOnListings

This mutation to map the token gating group with Mojito listings like Claim or Sale.

if the gating group or rule is mapped with a listing, the user can able to buy or claim the token by eligibility for gating rules.

Sample mutation

mutation enableTokenGatingOnListings($groupId: UUID1!, $ruleId: UUID1, $listingIds: [UUID1!]!) {
  enableTokenGatingOnListings(
    groupId: $groupId
    ruleId: $ruleId
    listingIds: $listingIds
  )
}

Sample variable

{
  "groupId": "553e893f-66df-425e-8833-bb5c21c61b07",
  "ruleId": "98799280-7418-471b-a610-b6a2418c0954",
  "listingIds": [
    "ee4ca1f9-a534-4331-9345-10eb2ccf5167",
    "0c2ae7b0-8c1d-4c1a-bc1c-1dd01664f67b"
  ]
}

Sample response

{
  "data": {
    "enableTokenGatingOnListings": true
  }
}

Arguments

if we are mapping against the gating group, we need to pass the group ID alone, else need to against the specific rule should pass rule as well.

NameTypeDescriptionRequired
groupIdUUID1The token gating group id.Yes
ruleIdUUID1The token gating rule id.No

Fields

NameTypeDescription
trueor falseBooleansuccessfully mapped with listing it will return true else throw the respective error