Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Zora 0xsplits example? #2

Open
rubinovitz opened this issue Jun 4, 2024 · 14 comments
Open

Zora 0xsplits example? #2

rubinovitz opened this issue Jun 4, 2024 · 14 comments

Comments

@rubinovitz
Copy link

Hi I’m trying to create new Zora NFTs with variable revenue splits using an embedded privy wallet and 0xsplits.

do you have examples of your 0xsplits integration I can look at?

Thank you!

@oveddan
Copy link
Collaborator

oveddan commented Jun 4, 2024

hi @rubinovitz are you creating an onchain or premint contract/token?

@rubinovitz
Copy link
Author

Do you have any documentation on pre-mint? Was unaware it was an option and the one link on Google is broken. Also can't find it in your docs.

@oveddan
Copy link
Collaborator

oveddan commented Jun 4, 2024

hi @rubinovitz we don't currently have much documentation on Premint (we need to add it). but here's some documentation on it from the sdk standpoint:
https://ourzora.github.io/zora-protocol/protocol-sdk/premint-client

to get a better understanding of how it works, you could look at the code for the premint client here:
https://github.com/ourzora/zora-protocol/blob/main/packages/protocol-sdk/src/premint/premint-client.ts#L227

@rubinovitz
Copy link
Author

@oveddan thanks I think we’re going to do premint

@oveddan
Copy link
Collaborator

oveddan commented Jun 5, 2024

got it - splits on premint are not supported yet (but it's planned).

@rubinovitz
Copy link
Author

@oveddan ok in that case can we do onchain?

@iainnash
Copy link

Yes it can be done onchain – you can submit the split on chain before a premint or submit both the mint and the split onchain. You can just use the splits SDK/API and then submit that address to the contract payoutaddress.

@oveddan
Copy link
Collaborator

oveddan commented Jun 10, 2024

we should have this supported in our sdk soon

@oveddan
Copy link
Collaborator

oveddan commented Jun 13, 2024

hey we have an updated sdk and example for creating with splits, check it out here:
https://ourzora.github.io/zora-protocol/protocol-sdk/creator/splits

@rubinovitz
Copy link
Author

@oveddan is your documentation for contract metadata correct? If so what is the difference between image and imageURI?

@mattleesounds
Copy link

@oveddan The collection metadata here https://docs.zora.co/docs/smart-contracts/creator-tools/Deploy1155Contract is what @rubinovitz is referring to.

I am also confused about how these two pages of documentation work together because there is also this one https://ourzora.github.io/zora-protocol/protocol-sdk/creator/onchain

@oveddan
Copy link
Collaborator

oveddan commented Jun 27, 2024

hey weve been migrating our docs so there is a bit of confusion/duplication between the two.

For now you can know that:

Contract metadata has the following json schema:

{
  "name": "{contract name}",
  "description": "{contract description}",
  "image": "{contract image}"
} 

Token metadata has the following json schema:

{
  "name": "{token name}",
  "description": "{token description}",
  "image": "{token image ipfs url}",
  "animation_url": "{token media ipfs url}",
  "content": {
    "mime": "{content mime type}",
    "uri": "{content ipfs uri}"
  },
  "attributes": {
    "trait_type": "{trait type}",
    "value": "{trait value}"
  }
}

Contract and token metadata should be pinned to IPFS using a preferred pinning service,
and the url when set on a contract or token should be in an ipfs url format, like: ipfs://{cid}

@rubinovitz
Copy link
Author

rubinovitz commented Jun 27, 2024 via email

@mattleesounds
Copy link

mattleesounds commented Jul 8, 2024

Screenshot 2024-07-08 at 8 32 39 AM
@oveddan It appears that all fields in the contract metadata are optional. Does that mean that this json file itself is optional for creating an erc1155 collection?

Clearly, there needs to be a contract to create a token, but I am confused as to why all fields in the contract metadata would be optional.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants