Wanted: bot which turns a webpage into an xdc

I would like to be able to turn almost any webpage into an xdc, like archiving it.
The bot will be presented with a URL, fetches the content, creates an icon.png/jpg, names it properly and downloads the xdc for further usage.

Is this doable?

1 Like

Bots already exist to which you can give a URL and they will reply with:

  • the whole website in a zip
  • the whole website in a webxdc
  • the bare HTML file content without styles in an HTML message
  • the page rendered in a browser for a few seconds, snapshotted into a small static HTML message

You can find the source code and hosted instances for most in:
https://deltachat-bot.github.io/public-bots/

This specific bot seems to be doing exactly what you ask for:

3 Likes

OMG, thanks will check it out.

doesn’t seem to work for me :expressionless:

You mean you tried to clone it and host it yourself and it had thrown an exception? I don’t think that @DavidSM100 @davidsm10 wanted to host it indefinitely.

well, no hosting here… but thanks

Maybe a browser extension would be better

Could you perhaps tell us more about what use case this would solve for people?

Archiving, taking a relevant page offline, sharing it later - securely

Archiving is the responsibility of libraries - web.archive.org already solves this.

You can download a whole page for your personal offline viewing either within the browser or through web extensions (bookmarklets) that snapshots and sanitizes the rendered DOM. Some archivists (such as the Archive Team) have already published specialized tools for this that can also be ran from the command line.

However, sharing such downloads later on publicly may raise copyright concerns unless the site in question is copyleft or at least CC-NC-ND.

Overall, I still don’t see where Delta Chat comes into the question.

xdc is a nice mechanism to handle/take offline html, css, js

I feel you already have some concrete website(s) in mind. Care to share a few? For example, would you like to encapsulate a whole portal with its navigation tabs, or certain games perhaps? A whole automatically generated manual of some software?

Not really, but think of Wallabag, it’s read later but grab the content since you never know it’s going to be there tomorrow

Isn’t that what the cache within web browsers was originally created for?

That’s a different feat

You can use SingleFile web extension to export a page as a .xdc file, you would need to tweak the settings a little though.

1 Like

Ah, you mean adding the Icon and the js, that’s a workaround! Still a dedicated one would be better