- API Reference
- LeadFyndr
- Get a simple lead. Use the unlocked route for more detail leads
Get a simple lead. Use the unlocked route for more detail leads
Request
- leadIdstringrequired
- customerIdstringrequired
Responses
The lead preview of a lead which is not unlocked yet.
- businessFieldsarray of stringrequired
- Array[
- *string
]
- companyobjectrequired
- countystringrequired
- employeeCountinteger (int64)
- foundingYearnumber
- salesVolumeinteger (int64)
- descriptionstringrequired
- hosterobjectrequired
- serverarray of stringrequired
- Array[
- *string
]
- languagesarray of stringrequired
- Array[
- *string
]
- leadIdstringrequired
- mainTechnologyobject
- categoriesarray of object
- Array[
- *object
- namestringrequired
- parentCategoriesarray of string
- Array[
- *string
]
- prioritynumberrequired
]
- categoryPriorityintegerrequired
- namestringrequired
- versionstring
- metricsobjectrequired
- co2number (≥ 0, float)
- contentLoadednumber (≥ 0, float)
- desktopobjectrequired
- accessibilitynumber (≥ 0, float)
- bestPracticenumber (≥ 0, float)
- cumulativeLayoutShiftnumber (≥ 0, float)
- firstContentfulPaintnumber (≥ 0, float)
- largestContentfulPaintnumber (≥ 0, float)
- performancenumber (≥ 0, float)
- seonumber (≥ 0, float)
- totalBlockingTimenumber (≥ 0, float)
- mobileobjectrequired
- accessibilitynumber (≥ 0, float)
- bestPracticenumber (≥ 0, float)
- cumulativeLayoutShiftnumber (≥ 0, float)
- firstContentfulPaintnumber (≥ 0, float)
- largestContentfulPaintnumber (≥ 0, float)
- performancenumber (≥ 0, float)
- seonumber (≥ 0, float)
- totalBlockingTimenumber (≥ 0, float)
- timeToFirstByteMsnumber
- potentialnumber (≥ 0, float)required
- scannedAtstring (date-time)
- screenshotstringrequired
- technologiesarray of objectrequired
- Array[
- *object
- categoriesarray of object
- Array[
- *object
- namestringrequired
- parentCategoriesarray of string
- Array[
- *string
]
- prioritynumberrequired
]
- categoryPriorityintegerrequired
- namestringrequired
- versionstring
]
Content-Type: application/json
{
"businessFields": [
"string"
],
"company": {
"county": "string",
"employeeCount": 123,
"foundingYear": 123,
"salesVolume": 123
},
"description": "string",
"hoster": {
"server": [
"string"
]
},
"languages": [
"string"
],
"leadId": "string",
"mainTechnology": {
"categories": [
{
"name": "string",
"parentCategories": [
"string"
],
"priority": 123
}
],
"categoryPriority": 123,
"name": "string",
"version": "string"
},
"metrics": {
"co2": 123,
"contentLoaded": 123,
"desktop": {
"accessibility": 123,
"bestPractice": 123,
"cumulativeLayoutShift": 123,
"firstContentfulPaint": 123,
"largestContentfulPaint": 123,
"performance": 123,
"seo": 123,
"totalBlockingTime": 123
},
"mobile": {
"accessibility": 123,
"bestPractice": 123,
"cumulativeLayoutShift": 123,
"firstContentfulPaint": 123,
"largestContentfulPaint": 123,
"performance": 123,
"seo": 123,
"totalBlockingTime": 123
},
"timeToFirstByteMs": 123
},
"potential": 123,
"scannedAt": "1985-10-26T01:21:00.000Z",
"screenshot": "string",
"technologies": [
{
"categories": [
{
"name": "string",
"parentCategories": [
"string"
],
"priority": 123
}
],
"categoryPriority": 123,
"name": "string",
"version": "string"
}
]
}
{
"properties": {
"businessFields": {
"items": {
"type": "string"
},
"type": "array"
},
"company": {
"properties": {
"county": {
"type": "string"
},
"employeeCount": {
"format": "int64",
"type": "integer"
},
"foundingYear": {
"type": "number"
},
"salesVolume": {
"format": "int64",
"type": "integer"
}
},
"required": [
"county"
],
"type": "object"
},
"description": {
"type": "string"
},
"hoster": {
"properties": {
"server": {
"items": {
"type": "string"
},
"type": "array"
}
},
"required": [
"server"
],
"type": "object"
},
"languages": {
"items": {
"type": "string"
},
"type": "array"
},
"leadId": {
"type": "string"
},
"mainTechnology": {
"properties": {
"categories": {
"items": {
"properties": {
"name": {
"type": "string"
},
"parentCategories": {
"items": {
"type": "string"
},
"type": "array"
},
"priority": {
"type": "number"
}
},
"required": [
"name",
"priority"
],
"type": "object"
},
"type": "array"
},
"categoryPriority": {
"type": "integer"
},
"name": {
"type": "string"
},
"version": {
"type": "string"
}
},
"required": [
"name",
"categoryPriority"
],
"type": "object"
},
"metrics": {
"properties": {
"co2": {
"format": "float",
"minimum": 0,
"type": "number"
},
"contentLoaded": {
"format": "float",
"minimum": 0,
"type": "number"
},
"desktop": {
"properties": {
"accessibility": {
"format": "float",
"maximum": 1,
"minimum": 0,
"type": "number"
},
"bestPractice": {
"format": "float",
"maximum": 1,
"minimum": 0,
"type": "number"
},
"cumulativeLayoutShift": {
"format": "float",
"minimum": 0,
"type": "number"
},
"firstContentfulPaint": {
"format": "float",
"minimum": 0,
"type": "number"
},
"largestContentfulPaint": {
"format": "float",
"minimum": 0,
"type": "number"
},
"performance": {
"format": "float",
"maximum": 1,
"minimum": 0,
"type": "number"
},
"seo": {
"format": "float",
"maximum": 1,
"minimum": 0,
"type": "number"
},
"totalBlockingTime": {
"format": "float",
"minimum": 0,
"type": "number"
}
},
"type": "object"
},
"mobile": {
"properties": {
"accessibility": {
"format": "float",
"maximum": 1,
"minimum": 0,
"type": "number"
},
"bestPractice": {
"format": "float",
"maximum": 1,
"minimum": 0,
"type": "number"
},
"cumulativeLayoutShift": {
"format": "float",
"minimum": 0,
"type": "number"
},
"firstContentfulPaint": {
"format": "float",
"minimum": 0,
"type": "number"
},
"largestContentfulPaint": {
"format": "float",
"minimum": 0,
"type": "number"
},
"performance": {
"format": "float",
"maximum": 1,
"minimum": 0,
"type": "number"
},
"seo": {
"format": "float",
"maximum": 1,
"minimum": 0,
"type": "number"
},
"totalBlockingTime": {
"format": "float",
"minimum": 0,
"type": "number"
}
},
"type": "object"
},
"timeToFirstByteMs": {
"type": "number"
}
},
"required": [
"desktop",
"mobile"
],
"type": "object"
},
"potential": {
"format": "float",
"maximum": 1,
"minimum": 0,
"type": "number"
},
"scannedAt": {
"format": "date-time",
"type": "string"
},
"screenshot": {
"type": "string"
},
"technologies": {
"items": {
"properties": {
"categories": {
"items": {
"properties": {
"name": {
"type": "string"
},
"parentCategories": {
"items": {
"type": "string"
},
"type": "array"
},
"priority": {
"type": "number"
}
},
"required": [
"name",
"priority"
],
"type": "object"
},
"type": "array"
},
"categoryPriority": {
"type": "integer"
},
"name": {
"type": "string"
},
"version": {
"type": "string"
}
},
"required": [
"name",
"categoryPriority"
],
"type": "object"
},
"type": "array"
}
},
"required": [
"leadId",
"potential",
"screenshot",
"company",
"metrics",
"businessFields",
"description",
"technologies",
"hoster",
"languages"
],
"type": "object"
}
Validation Error caused by invalid input data in the request
- type"ValidationError"required
- messagestring
- validationErrorsarray of objectrequired
- Array[
- *object
- messagestringrequired
The standard error message
- pathstringrequired
The path to the part of the data that was validated. JavaScript property access notation (e.g., ".prop[1].subProp") is used.
- typestringrequired
ajv validation error type (e.g. "format", "required", "type") or own validation error types
- contextobject
The object with the additional information about the error that can be used to create custom error messages. Keys depend on the type that failed validation (e.g. "missingProperty" for type "required")
- *string
]
Content-Type: application/json
{
"type": "ValidationError",
"message": "Validation failed",
"validationErrors": [
{
"message": "should be string",
"path": ".address.street",
"type": "format",
"context": {
"format": "email"
}
}
]
}
{
"type": "object",
"required": [
"type",
"validationErrors"
],
"properties": {
"type": {
"type": "string",
"enum": [
"ValidationError"
]
},
"message": {
"type": "string",
"example": "Validation failed"
},
"validationErrors": {
"type": "array",
"items": {
"type": "object",
"required": [
"message",
"path",
"type"
],
"properties": {
"message": {
"type": "string",
"description": "The standard error message",
"example": "should be string"
},
"path": {
"type": "string",
"description": "The path to the part of the data that was validated. JavaScript property access notation (e.g., \".prop[1].subProp\") is used.\n",
"example": ".address.street"
},
"type": {
"type": "string",
"description": "ajv validation error type (e.g. \"format\", \"required\", \"type\") or own validation error types",
"example": "format"
},
"context": {
"type": "object",
"example": {
"format": "email"
},
"description": "The object with the additional information about the error that can be used to create custom error messages. Keys depend on the\ntype that failed validation (e.g. \"missingProperty\" for type \"required\")\n",
"additionalProperties": {
"type": "string"
}
}
}
}
}
}
}
An unexpected Error that occurred while handling the request
- messagestringrequired
- typestringrequired
Content-Type: application/json
{
"message": "Something went wrong",
"type": "InternalServerError"
}
{
"type": "object",
"required": [
"type",
"message"
],
"properties": {
"message": {
"type": "string",
"example": "Something went wrong"
},
"type": {
"type": "string",
"example": "InternalServerError"
}
}
}
The requested resource was not found
- messagestringrequired
- typestringrequired
Content-Type: application/json
{
"message": "Something went wrong",
"type": "InternalServerError"
}
{
"type": "object",
"required": [
"type",
"message"
],
"properties": {
"message": {
"type": "string",
"example": "Something went wrong"
},
"type": {
"type": "string",
"example": "InternalServerError"
}
}
}
Your request ran into a rate limit. You have to wait until rate limit expires
- messagestring
- typestring
Content-Type: application/json
{
"message": "too many requests",
"type": "RateLimitError"
}
{
"type": "object",
"properties": {
"message": {
"type": "string",
"example": "too many requests"
},
"type": {
"type": "string",
"example": "RateLimitError"
}
}
}
An unexpected Error that occurred while handling the request
- messagestringrequired
- typestringrequired
Content-Type: application/json
{
"message": "Something went wrong",
"type": "InternalServerError"
}
{
"type": "object",
"required": [
"type",
"message"
],
"properties": {
"message": {
"type": "string",
"example": "Something went wrong"
},
"type": {
"type": "string",
"example": "InternalServerError"
}
}
}
Usage examples
$ curl \
--fail \
--location \
-H "Authorization: Bearer $MITTWALD_API_TOKEN" \
https://api.mittwald.de/v2/customers/string/leads/string
import { MittwaldAPIV2Client } from "@mittwald/api-client";
import { assertStatus } from "@mittwald/api-client-commons";
const client = MittwaldAPIClient.newWithToken(process.env.MITTWALD_API_TOKEN);
const response = await client.leadFyndr.getLead({
"leadId": "string",
"customerId": "string"
});
assertStatus(response, 200);
use \Mittwald\ApiClient\Generated\V2\Clients\LeadFyndr\GetLead\GetLeadRequest;
$client = MittwaldAPIClient::newWithToken(getenv('MITTWALD_API_TOKEN'));
$request = (new GetLeadRequest(
leadId: "string",
customerId: "string"
));
$response = $client->leadFyndr()->getLead($request);
var_dump($response->getBody();