← Back to Use Cases
COLLABORATION & SHARING

Lightweight Form Backend

Collect feedback/support tickets by posting to a stash; team reads with master token.

The Problem

You have a static website with a contact form. You need somewhere to collect submissions without setting up a backend server or database.

The WrenDB Solution

Point your form at WrenDB. Each submission creates a new item you can review later.

Complete Example

Example
<form action="https://wrendb.com/api/item/YOUR_STASH_ID" method="POST">
  <input type="text" name="name" placeholder="Your name" required>
  <input type="email" name="email" placeholder="Email" required>
  <textarea name="message" placeholder="Message" required></textarea>
  <button type="submit">Send Message</button>
</form>

<!-- For better UX, use JavaScript -->
<script>
document.querySelector('form').addEventListener('submit', async (e) => {
  e.preventDefault();
  const formData = new FormData(e.target);
  const data = Object.fromEntries(formData);
  
  await fetch('https://wrendb.com/api/item/YOUR_STASH_ID', {
    method: 'POST',
    headers: {'Content-Type': 'application/json'},
    body: JSON.stringify(data)
  });
  
  alert('Message sent!');
  e.target.reset();
});
</script>

Related Use Cases

Presigned-Writes Config Sharing