this post was submitted on 19 Feb 2025
7 points (81.8% liked)

Android

28940 readers
328 users here now

DROID DOES

Welcome to the droidymcdroidface-iest, Lemmyest (Lemmiest), test, bestest, phoniest, pluckiest, snarkiest, and spiciest Android community on Lemmy (Do not respond)! Here you can participate in amazing discussions and events relating to all things Android.

The rules for posting and commenting, besides the rules defined here for lemmy.world, are as follows:

Rules


1. All posts must be relevant to Android devices/operating system.


2. Posts cannot be illegal or NSFW material.


3. No spam, self promotion, or upvote farming. Sources engaging in these behavior will be added to the Blacklist.


4. Non-whitelisted bots will be banned.


5. Engage respectfully: Harassment, flamebaiting, bad faith engagement, or agenda posting will result in your posts being removed. Excessive violations will result in temporary or permanent ban, depending on severity.


6. Memes are not allowed to be posts, but are allowed in the comments.


7. Posts from clickbait sources are heavily discouraged. Please de-clickbait titles if it needs to be submitted.


8. Submission statements of any length composed of your own thoughts inside the post text field are mandatory for any microblog posts, and are optional but recommended for article/image/video posts.


Community Resources:


We are Android girls*,

In our Lemmy.world.

The back is plastic,

It's fantastic.

*Well, not just girls: people of all gender identities are welcomed here.


Our Partner Communities:

[email protected]


founded 2 years ago
MODERATORS
 

I'm a web developer, mostly with Python and have close to zero Java or Kotlin experience, but I want to build a bunch of tools for my phone where I can Share a URL (for example) to an app that simply takes that URL string and sends an HTTP POST request to a pre-arranged URL with some pre-arranged headers or POST data.

So basically I'm looking for an app that:

  • Lets you define a series of endpoints
  • Accepts share intents from other apps to then bring up a selector asking "Which endpoint do you want to send this to?", sends it, and exits.

It seems a little nuts that I should have to develop a separate app for each endpoint, when the app experience isn't really something I'm interested in. Can someone here point me to an app that already does something like this? I'd prefer a FOSS option if possible, but at this point I don't even know what to search for.

Example use-cases:

  • Send a YouTube URL to a service that downloads said video and stores it on a share on my VPN
  • Send a text snippet to a service that stores that snippet as a Markdown file for use as ideas for future blog posts
  • Send an article URL to a service that strips the ads and images out and saves a Markdown file for future reading.
top 13 comments
sorted by: hot top controversial new old
[–] [email protected] 1 points 2 days ago

You can check out Tasker, a powerful Android automation app that might help with your use case. You can create custom actions for HTTP POST requests triggered by share intents. For instance, you can define a task to send a URL to a specific endpoint, and then have Tasker execute the HTTP POST with the necessary headers and data. It's a bit of a learning curve, but there are plenty of resources online to get started.

By the way, you can also check out this link for viewing Markdown files more easily.

[–] [email protected] 2 points 2 days ago (1 children)

I'm also more familiar with web dev, so you might just slap together a web app as a PWA, configure it as a share target, and install that, instead of learning the whole android app dev process.

[–] [email protected] 1 points 2 days ago (1 children)

Woah, you can configure a website as a share target? How do I do that?

[–] [email protected] 1 points 2 days ago

I just googled "PWA share target" and got a bunch of results. I'm sure some of them will be relevant to you.

[–] [email protected] 1 points 2 days ago* (last edited 2 days ago) (1 children)

I think the only thing that could come close to what you want would be an automation centric app like Tasker or Automate. Neither are FOSS, but they're really good.

Edit: Found exactly what you need on F-Droid, it's called HTTP Request Shortcuts.

[–] [email protected] 1 points 2 days ago* (last edited 2 days ago)

I've not used it but this might be an alternative.

Edit: Looks like it can indeed send/receive webhooks

[–] PetteriPano 1 points 2 days ago* (last edited 2 days ago) (1 children)

I like to make bookmarklets for these kind of things.

Just make a page with a link that runs a javascript snippet. Drag that link to your bookmark bar, and you have a new action button. Firefox syncs them from desktop to mobile, there's probably a way to add them straight on your mobile browser, too.

The snippet could post the current URL, post what you've currently selected. Tinyurl has an example for creating a tinyurl from where you are - probably a good starting point.

I've got one that posts to my personal URL shortener. One that grabs metadata from a ticketing system and makes nice linky markdown in my clipboard for me to paste on slack.

[–] bus_factor 0 points 2 days ago (1 children)

Are you doing this in a desktop browser or on Android? OP is asking about Android.

[–] PetteriPano 1 points 2 days ago

They work on both desktop and android versions of Firefox, at least. I haven't tried other android browsers, but I'd expect it to work.

[–] turmacar 1 points 2 days ago (1 children)

Are you looking for something like Pocket?

There are self-hosted things a lot like it. Vivaldi and some other browsers have similar functionality. Not sure about downloading the videos, but there are other tools for that.

[–] [email protected] 1 points 2 days ago (1 children)

Pocket will fill in a pinch, but it's a very specific use cases and I'm looking for something more general. For example, it'd be nice to write something that accepts location data from Google maps and dumps it on a database for plotting later if something. I'm looking for a general tool that lets me be creative with my phone :-)

[–] turmacar 3 points 2 days ago (1 children)

There's always Tasker.

It's stupidly powerful once you get used to how it works, even without root, and it can definitely patch into the default "share" functionality.

[–] [email protected] 1 points 2 days ago

I'd forgotten about Tasker. I'll give that a try, thanks!