deltachat-core-rust icon indicating copy to clipboard operation
deltachat-core-rust copied to clipboard

not possible to send webxdc app staged in draft with JSON-RPC API

Open adbenitez opened this issue 1 year ago • 7 comments

it is common need to stag a webxdc app to setup its state before sending it, that is set the app as draft (like on DC android), but with current JSON-RPC API it is not possible to send the staged draft, or send a new message with status updates set

adbenitez avatar Aug 30 '23 02:08 adbenitez

Why did you add the jsonrpc label if you want to have a more powerful webxdc api? I guess you are talking about sending staged webxdcs from within other webxdcs?

Septias avatar Oct 08 '23 20:10 Septias

could you close this issue and, if needed, open a new one, at best after a discussion with Bjoern or so, and try to phrase it as an actionable item for core? I am btw not sure i understand precisely -- staging in android including creating some app-updates works but that's probably not what you mean?

hpk42 avatar Oct 09 '23 11:10 hpk42

imu, the issue is, that jsonrpc does not allow to stage+prepare webxdc apps in draft mode (so, desktop cannot implement stage+prepare)

otoh, stage+prepare webxdc apps is possible in cffi (android/ios use cffi and allow stage+prepare therefore)

so, the actionable item is to modify the jsonrpc so that stage+prepare webxdc apps is possible.

i also had to re-read several times - the issue makes sense only if you read the tag as well - in general, i think, issue texts should be understandable by not reading tags or headlines (which should only summarise and organise) - but i am sure, i am am also sometimes failing on that :)

r10s avatar Oct 09 '23 18:10 r10s

thanks @r10s, yes that was the intention, I edited the post, the issue is I made a typo and said "webxdc api" instead of "jsonrpc api" that is why everyone else was confused :sweat_smile:

this issue is an important stepping stone so DC Desktop can add staging/drafting of webxdc apps before sending them

adbenitez avatar Oct 10 '23 15:10 adbenitez

thanks @r10s, yes that was the intention, I edited the post, the issue is I made a typo and said "webxdc api" instead of "jsonrpc api" that is why everyone else was confused 😅

this issue is an important stepping stone so DC Desktop can add staging/drafting of webxdc apps before sending them

you still didn't address my comment, though -- which would mean maybe something like "implement json-rpc support for staging draft webxdc apps" -- linking the existing CFFI functions in the description.

There is another related practise i discussed with link2xt and r10s yesterday: core API issues and PRs should have a corresponding UI PR and not be done and discussed independently from usage. So if there is no ongoing work/PR to use a new jsonrpc-api i suggest to close this issue here.

hpk42 avatar Oct 10 '23 15:10 hpk42

closing because there does not seem to be a need for this. Feel free to reopen if I'm wrong @adbenitez

Septias avatar Oct 15 '23 15:10 Septias

There is a corresponding desktop issue: https://github.com/deltachat/deltachat-desktop/issues/2722

New deltachat-rpc-client bindings are now uploaded to PyPI #4523. New JSON-RPC bindings are no longer experimental, e.g. [email protected] and matterbridge are using it, so bots will also need this if they want to prepare .xdc before sending.

link2xt avatar Oct 15 '23 18:10 link2xt