Getting Started
Contact Form Service is a Docker-ready backend that receives contact form submissions from your website and forwards them to Slack. Drop it in front of any static site or web app to get instant lead notifications without building a custom backend. Available as an open web service in Eyevinn Open Source Cloud.
Prerequisites
- If you have not already done so, sign up for an Eyevinn OSC account
- A Slack workspace with a bot token (required when using the
slacktransport)
Step 1: Create a Slack bot (optional, for Slack transport)
If you want form submissions delivered to Slack:
- Go to api.slack.com/apps and create a new app.
- Under OAuth & Permissions, add the
chat:writescope and install the app to your workspace. - Copy the Bot User OAuth Token (starts with
xoxb-). - Invite the bot to the channel where you want notifications.
Step 2: Store credentials as service secrets
Navigate to the Contact Form Service page, go to the Service Secrets tab, and create:
slacktoken— your Slack bot token (xoxb-...)
Step 3: Create a Contact Form Service instance
Go to the My contact-form-svcs tab and click Create contact-form-svc. Fill in:
- Name: a unique name (e.g.
mycontact) - Transport:
slackto forward to Slack, ordummyfor testing (logs to console only) - SlackBotToken:
{{secrets.slacktoken}} - SlackChannelId: the Slack channel ID where notifications should be posted (e.g.
C0XXXXXXX)
Click Create and wait for the status indicator to turn green.
Step 4: Send a test submission
With the instance running, submit a contact form via the API:
curl -X POST https://<instance-url>/contact \
-H "Content-Type: application/json" \
-d '{"name": "Alice", "email": "alice@example.com", "message": "Hello!"}'
A 200 response confirms the message was accepted. With the slack transport, the submission appears in your configured Slack channel within seconds.
Integrating with a static website
Point your HTML form's action at the service URL:
<form method="POST" action="https://<instance-url>/contact">
<input name="name" placeholder="Your name" required />
<input name="email" type="email" placeholder="Email" required />
<textarea name="message" placeholder="Message" required></textarea>
<button type="submit">Send</button>
</form>
Or submit via JavaScript:
await fetch('https://<instance-url>/contact', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ name, email, message }),
});
CLI usage
# With Slack transport
osc create birme-contact-form-svc mycontact \
-o Transport="slack" \
-o SlackBotToken="{{secrets.slacktoken}}" \
-o SlackChannelId="C0XXXXXXX"
# Dummy transport (for testing)
osc create birme-contact-form-svc mycontact -o Transport="dummy"