melanie

melanie / letterbird-params.md

Last active 4 months ago

Like 0

melanie revised this gist 2 years ago · 8e1dc05

No changes

melanie revised this gist 2 years ago · 0b2b392

No changes

melanie revised this gist 2 years ago · c2f1ba0

No changes

melanie revised this gist 2 years ago · 36fcad4

1 file changed, 15 insertions

letterbird-params.md (file created)
@@ -0,0 +1,15 @@
1 + # Undocumented Query Parameters You Can Use With Letterbird URLS
2 +
3 + Example URL: `https://letterbird.co/melanie`
4 +
5 + Using every parameter in the example URL: `https://letterbird.co/melanie?name=from&email=email&body=body&subject=subject&hideheader=1`
6 +
7 + - `hideheader=1` - hides the header and profile picture
8 + - `name=` - Pre-fills the from name field
9 + - `email=` - Pre-fills the from email field
10 + - `body=` - Pre-fills the body text area
11 + - `subject=` - Pre-fills the subject field if enabled
12 +
13 + As always with query parameters, you should probably run the strings you want to use as the value through `encodeURIComponent()` so that things like spaces become `%20`, newlines become `%0A`, and @ symbols become `%40`.
14 +
15 + Of note, sometimes Letterbird will try to store some of these values in localStorage to hold on to what the user has inputted manually and it will overwrite the query parameters.