Simple integration guide for sending orders, leads, and meeting bookings to SwiftCrew
Include these headers in all API requests:
x-business-id: YOUR_BUSINESS_ID x-api-key: YOUR_API_KEY x-secret-key: YOUR_SECRET_KEY Content-Type: application/json
Send WooCommerce orders to SwiftCrew with real-time CallKit notifications for iOS.
curl -X POST https://api.swiftcrew.cloud/createWoocommerceOrder \
-H "Content-Type: application/json" \
-H "x-business-id: YOUR_BUSINESS_ID" \
-H "x-api-key: YOUR_API_KEY" \
-H "x-secret-key: YOUR_SECRET_KEY" \
-d '{
"orderData": {
"orderId": "12345",
"customerName": "John Smith",
"customerEmail": "[email protected]",
"totalAmount": 299.99,
"status": "processing",
"items": [
{
"id": 1,
"name": "Product Name",
"quantity": 1,
"price": 299.99
}
]
}
}'
const response = await fetch('https://api.swiftcrew.cloud/createWoocommerceOrder', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'x-business-id': 'YOUR_BUSINESS_ID',
'x-api-key': 'YOUR_API_KEY',
'x-secret-key': 'YOUR_SECRET_KEY'
},
body: JSON.stringify({
orderData: {
orderId: "12345",
customerName: "John Smith",
customerEmail: "[email protected]",
totalAmount: 299.99,
status: "processing",
items: [{
id: 1,
name: "Product Name",
quantity: 1,
price: 299.99
}]
}
})
});
const result = await response.json();
console.log(result);
import requests
import json
url = "https://api.swiftcrew.cloud/createWoocommerceOrder"
headers = {
"Content-Type": "application/json",
"x-business-id": "YOUR_BUSINESS_ID",
"x-api-key": "YOUR_API_KEY",
"x-secret-key": "YOUR_SECRET_KEY"
}
data = {
"orderData": {
"orderId": "12345",
"customerName": "John Smith",
"customerEmail": "[email protected]",
"totalAmount": 299.99,
"status": "processing",
"items": [{
"id": 1,
"name": "Product Name",
"quantity": 1,
"price": 299.99
}]
}
}
response = requests.post(url, headers=headers, json=data)
print(response.json())
const axios = require('axios');
const orderData = {
orderData: {
orderId: "12345",
customerName: "John Smith",
customerEmail: "[email protected]",
totalAmount: 299.99,
status: "processing",
items: [{
id: 1,
name: "Product Name",
quantity: 1,
price: 299.99
}]
}
};
try {
const response = await axios.post(
'https://api.swiftcrew.cloud/createWoocommerceOrder',
orderData,
{
headers: {
'Content-Type': 'application/json',
'x-business-id': 'YOUR_BUSINESS_ID',
'x-api-key': 'YOUR_API_KEY',
'x-secret-key': 'YOUR_SECRET_KEY'
}
}
);
console.log(response.data);
} catch (error) {
console.error(error.response.data);
}
{"error":{"message":"Authentication required. Use Bearer token or legacy headers (x-business-id, x-api-key, x-secret-key)","status":"UNAUTHENTICATED"}}
Capture leads from web forms, landing pages, or any source.
curl -X POST https://api.swiftcrew.cloud/receiveWebLead \
-H "Content-Type: application/json" \
-H "x-business-id: YOUR_BUSINESS_ID" \
-H "x-api-key: YOUR_API_KEY" \
-H "x-secret-key: YOUR_SECRET_KEY" \
-d '{
"name": "Jane Doe",
"email": "[email protected]",
"phone": "+1-555-0123",
"message": "Interested in your services",
"source": "Website Form"
}'
const response = await fetch('https://api.swiftcrew.cloud/receiveWebLead', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'x-business-id': 'YOUR_BUSINESS_ID',
'x-api-key': 'YOUR_API_KEY',
'x-secret-key': 'YOUR_SECRET_KEY'
},
body: JSON.stringify({
name: "Jane Doe",
email: "[email protected]",
phone: "+1-555-0123",
message: "Interested in your services",
source: "Website Form"
})
});
const result = await response.json();
console.log(result);
import requests
url = "https://api.swiftcrew.cloud/receiveWebLead"
headers = {
"Content-Type": "application/json",
"x-business-id": "YOUR_BUSINESS_ID",
"x-api-key": "YOUR_API_KEY",
"x-secret-key": "YOUR_SECRET_KEY"
}
data = {
"name": "Jane Doe",
"email": "[email protected]",
"phone": "+1-555-0123",
"message": "Interested in your services",
"source": "Website Form"
}
response = requests.post(url, headers=headers, json=data)
print(response.json())
const axios = require('axios');
const leadData = {
name: "Jane Doe",
email: "[email protected]",
phone: "+1-555-0123",
message: "Interested in your services",
source: "Website Form"
};
try {
const response = await axios.post(
'https://api.swiftcrew.cloud/receiveWebLead',
leadData,
{
headers: {
'Content-Type': 'application/json',
'x-business-id': 'YOUR_BUSINESS_ID',
'x-api-key': 'YOUR_API_KEY',
'x-secret-key': 'YOUR_SECRET_KEY'
}
}
);
console.log(response.data);
} catch (error) {
console.error(error.response.data);
}
Swift Crew API
Swift Crew API
Hosting rewrites route API requests to Cloud Functions.
Leads endpoint: POST /v1/leads
Headers:
- x-business-id
- x-api-key
- x-secret-key
- Content-Type: application/json
Body (only name required):
{
"name": "John Doe"
}
Create appointment bookings and check availability.
curl -X POST https://api.swiftcrew.cloud/createBooking \
-H "Content-Type: application/json" \
-H "x-business-id: YOUR_BUSINESS_ID" \
-H "x-api-key: YOUR_API_KEY" \
-H "x-secret-key: YOUR_SECRET_KEY" \
-d '{
"clientName": "John Smith",
"clientEmail": "[email protected]",
"serviceId": "service_consultation",
"appointmentDate": "2024-01-15",
"startTime": "2024-01-15T14:00:00Z",
"endTime": "2024-01-15T15:00:00Z"
}'
const response = await fetch('https://api.swiftcrew.cloud/createBooking', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'x-business-id': 'YOUR_BUSINESS_ID',
'x-api-key': 'YOUR_API_KEY',
'x-secret-key': 'YOUR_SECRET_KEY'
},
body: JSON.stringify({
clientName: "John Smith",
clientEmail: "[email protected]",
serviceId: "service_consultation",
appointmentDate: "2024-01-15",
startTime: "2024-01-15T14:00:00Z",
endTime: "2024-01-15T15:00:00Z"
})
});
const result = await response.json();
console.log(result);
import requests
url = "https://api.swiftcrew.cloud/createBooking"
headers = {
"Content-Type": "application/json",
"x-business-id": "YOUR_BUSINESS_ID",
"x-api-key": "YOUR_API_KEY",
"x-secret-key": "YOUR_SECRET_KEY"
}
data = {
"clientName": "John Smith",
"clientEmail": "[email protected]",
"serviceId": "service_consultation",
"appointmentDate": "2024-01-15",
"startTime": "2024-01-15T14:00:00Z",
"endTime": "2024-01-15T15:00:00Z"
}
response = requests.post(url, headers=headers, json=data)
print(response.json())
const axios = require('axios');
const bookingData = {
clientName: "John Smith",
clientEmail: "[email protected]",
serviceId: "service_consultation",
appointmentDate: "2024-01-15",
startTime: "2024-01-15T14:00:00Z",
endTime: "2024-01-15T15:00:00Z"
};
try {
const response = await axios.post(
'https://api.swiftcrew.cloud/createBooking',
bookingData,
{
headers: {
'Content-Type': 'application/json',
'x-business-id': 'YOUR_BUSINESS_ID',
'x-api-key': 'YOUR_API_KEY',
'x-secret-key': 'YOUR_SECRET_KEY'
}
}
);
console.log(response.data);
} catch (error) {
console.error(error.response.data);
}
Swift Crew API
Swift Crew API
Hosting rewrites route API requests to Cloud Functions.
Leads endpoint: POST /v1/leads
Headers:
- x-business-id
- x-api-key
- x-secret-key
- Content-Type: application/json
Body (only name required):
{
"name": "John Doe"
}
Need help with integration or support for other platforms?
Email us: [email protected]