Video SDK

Integrate token gated video directly into your custom site!

Our video SDK enables token gated video directly on a custom Javascript site.

Use Case Example

You, as a creator, have a personal website and want to embed videos that you want a user to own an NFT to watch.

How It Works

  • Upload the videos that you want to token gate as unlisted Youtube videos.

  • Create token gated links for each video on MintGate to obtain the MintGate ID.

  • Download the NPM packagearrow-up-right into the Javascript site.

yarn add @mintgate/mintgate-js

OR 

npm install @mintgate/mintgate-js
  • Add this code to the webpage

const linkID = 'whateveryourmintgatelinkIDforthevideois'; 

function App() {
  const ref = useRef();
  useEffect(()=> {
    if(!ref) return;

    mintgate.embedVideo(linkID, ref.current)
      .then(x=>console.log('done'));
  }, [ref]);

  return (
    <div ref={ref}></div>
  );
}

NPM Package: https://www.npmjs.com/package/@mintgate/mintgate-jsarrow-up-right

circle-info

If you have questions or need support, message us on Discord at discord.gg/HVsbWZfrFQarrow-up-right or email us at support@mintgate.io.

Last updated