Crossbell-Box / xLog

🪽 An open-source creative community written on the blockchain.
https://xlog.app
Other
2.37k stars 224 forks source link

Unsure Idea: API for xLog #615

Open songkeys opened 1 year ago

songkeys commented 1 year ago

Note This is an immature idea. Let's consider and discuss if developers or users would truly benefit from this idea. We want to ensure we don't waste time implementing useless things.

Background

I'm aware of the crossbell.js indexer API that can query anything on the blockchain. But what if we had specific APIs for xLog?

Benefits

Drawbacks

Examples

Reads:

Writes:

I'm not sure if this would make things more complex - If the user has authorized siwe + operator, they can use the token to write with API (just another wrapper of the /op APIs on the current indexer)

enpitsuLin commented 1 year ago

IMO, providing a series of APIs, can make xLog more of a platform than just an app

I tried using crossbell.js to build a simple blog for using xLog's data as CMS just for study

as a universal lib, crossbel.js really can do this, but I had to wrap a lot of stuff for querying specific things in xLog


I think we should turn this into a discussion where is the discussions tab or discuss this topic in Discord?

DIYgod commented 1 year ago

In addition, I really want to expand Crossbell's notes API for more convenient content classification and recommendation, but it seems difficult to achieve.

songkeys commented 1 year ago

I think we should turn this into a discussion where is the discussions tab or discuss this topic in Discord?

@enpitsuLin We don't have the discussions tab so far. We could have one but I think there would be too many places for "discussions" (issues tab, discussions tab, discord channels).

In addition, I really want to expand Crossbell's notes API for more convenient content classification and recommendation, but it seems difficult to achieve.

@DIYgod Could you elaborate more on this?

Innei commented 1 year ago

IMO, providing a series of APIs, can make xLog more of a platform than just an app

I tried using crossbell.js to build a simple blog for using xLog's data as CMS ~just for study~

as a universal lib, crossbel.js really can do this, but I had to wrap a lot of stuff for querying specific things in xLog

I think we should turn this into a discussion ~where is the discussions tab~ or discuss this topic in Discord?

I am also like you, now publishing to xlog in mx-space/admin is also implemented through crossbell.js and unidata.

Gianthard-cyh commented 1 year ago

Any progress on this?

hyoban commented 8 months ago

Hi @Songkeys, this sounds like an interesting thing for me.

In sakuin, I must find xLog-related attributes in metadata.content.attributes. There is no type safety, I need to make sure there is this attribute or not.

I'd love to work on this in my free time, maybe start with a sdk for xLog.

songkeys commented 8 months ago

@hyoban I appreciate that you could pick this up. You could start with an API proposal. Let me know if we could help with anything here or in the Discord server.

hyoban commented 8 months ago

@Songkeys Because it should be a long task, maybe it will be more convenient to discuss on discord. I will get in touch with you there.