README.adoc 1.4 KB

12345678910111213141516171819202122232425262728293031
  1. = Gas Station Network (GSN)
  2. [.readme-notice]
  3. NOTE: This document is better viewed at https://docs.openzeppelin.com/contracts/api/gsn
  4. This set of contracts provide all the tools required to make a contract callable via the https://gsn.openzeppelin.com[Gas Station Network].
  5. TIP: If you're new to the GSN, head over to our xref:learn::sending-gasless-transactions.adoc[overview of the system] and basic guide to xref:ROOT:gsn.adoc[creating a GSN-capable contract].
  6. The core contract a recipient must inherit from is {GSNRecipient}: it includes all necessary interfaces, as well as some helper methods to make interacting with the GSN easier.
  7. Utilities to make writing xref:ROOT:gsn-strategies.adoc[GSN strategies] easy are available in {GSNRecipient}, or you can simply use one of our pre-made strategies:
  8. * {GSNRecipientERC20Fee} charges the end user for gas costs in an application-specific xref:ROOT:tokens.adoc#ERC20[ERC20 token]
  9. * {GSNRecipientSignature} accepts all relayed calls that have been signed by a trusted third party (e.g. a private key in a backend)
  10. You can also take a look at the two contract interfaces that make up the GSN protocol: {IRelayRecipient} and {IRelayHub}, but you won't need to use those directly.
  11. == Recipient
  12. {{GSNRecipient}}
  13. == Strategies
  14. {{GSNRecipientSignature}}
  15. {{GSNRecipientERC20Fee}}
  16. == Protocol
  17. {{IRelayRecipient}}
  18. {{IRelayHub}}