/hoses/create v1.0.0
Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.
Base URLs:
Hoses
postHosesCreate
Code samples
const inputBody = '{
"type": "object",
"required": [
"partNumber",
"brand",
"size"
],
"properties": {
"partNumber": {
"type": "string",
"description": "The part number, must be a non-empty string."
},
"brand": {
"type": "string",
"description": "The brand of the part, must be a non-empty string."
},
"size": {
"type": "string",
"description": "The size of the part, must be a non-empty string."
},
"nominalHoseSize": {
"type": "string",
"description": "The nominal size of the hose.",
"nullable": true
},
"description": {
"type": "string",
"description": "The description of the part.",
"nullable": true
},
"colourHose": {
"type": "string",
"description": "The color of the hose.",
"nullable": true
},
"colourLayLine": {
"type": "string",
"description": "The color of the lay line.",
"nullable": true
},
"colourLayLineText": {
"type": "string",
"description": "The color of the lay line text.",
"nullable": true
},
"series": {
"type": "string",
"description": "The series of the part.",
"nullable": true
},
"innerDiamInch": {
"type": "string",
"description": "The inner diameter in inches.",
"nullable": true
},
"spec": {
"type": "string",
"description": "The specification of the part.",
"nullable": true
},
"saeSpec": {
"type": "string",
"description": "The SAE specification of the part.",
"nullable": true
},
"isoSpec": {
"type": "string",
"description": "The ISO specification of the part.",
"nullable": true
},
"DN": {
"type": "string",
"description": "The DN specification of the part.",
"nullable": true
},
"isoClass": {
"type": "string",
"description": "The ISO class of the part.",
"nullable": true
},
"isoGrade": {
"type": "string",
"description": "The ISO grade of the part.",
"nullable": true
},
"isoType": {
"type": "string",
"description": "The ISO type of the part.",
"nullable": true
},
"reinforcement": {
"type": "string",
"description": "The reinforcement of the part.",
"nullable": true
},
"construction": {
"type": "string",
"description": "The construction of the part.",
"nullable": true
},
"colour": {
"type": "string",
"description": "The color of the part.",
"nullable": true
},
"temperatureRange": {
"type": "string",
"description": "The temperature range of the part.",
"nullable": true
},
"cover": {
"type": "string",
"description": "The cover of the part.",
"nullable": true
},
"tube": {
"type": "string",
"description": "The tube of the part.",
"nullable": true
},
"generalApplications": {
"type": "string",
"description": "The general applications of the part.",
"nullable": true
},
"impulseCycles": {
"type": "string",
"description": "The impulse cycles of the part.",
"nullable": true
},
"maxTempAir": {
"type": "string",
"description": "The maximum temperature for air.",
"nullable": true
},
"material": {
"type": "string",
"description": "The material of the part.",
"nullable": true
},
"maxPressurePsi": {
"type": "number",
"format": "decimal",
"description": "The maximum pressure in PSI.",
"nullable": true
},
"outerDiamInch": {
"type": "number",
"format": "decimal",
"description": "The outer diameter in inches.",
"nullable": true
},
"reinforcementDiamInch": {
"type": "number",
"format": "decimal",
"description": "The reinforcement diameter in inches.",
"nullable": true
},
"minBendRadiusInch": {
"type": "number",
"format": "decimal",
"description": "The minimum bend radius in inches.",
"nullable": true
},
"WeightLbs": {
"type": "number",
"format": "decimal",
"description": "The weight in pounds.",
"nullable": true
},
"burstPressurePsi": {
"type": "number",
"format": "decimal",
"description": "The burst pressure in PSI.",
"nullable": true
},
"standardLength": {
"type": "array",
"items": {
"type": "string"
},
"description": "The standard lengths of the part.",
"nullable": true
},
"recommendedCouplingSeries": {
"type": "array",
"items": {
"type": "string"
},
"description": "The recommended coupling series for the part.",
"nullable": true
},
"minTemp": {
"type": "array",
"items": {
"type": "string"
},
"description": "The minimum temperatures for the part.",
"nullable": true
},
"maxTemp": {
"type": "array",
"items": {
"type": "string"
},
"description": "The maximum temperatures for the part.",
"nullable": true
},
"type": {
"type": "array",
"items": {
"type": "string"
},
"description": "The types of the part.",
"nullable": true
},
"crimpSpecs": {
"type": "array",
"items": {
"type": "object",
"required": [
"couplingSeries",
"couplingSeriesBrand"
],
"properties": {
"couplingSeries": {
"type": "string",
"description": "The coupling series, must be a non-empty string."
},
"couplingSeriesBrand": {
"type": "string",
"description": "The brand of the coupling series, must be a non-empty string."
},
"ferrulePartNumber": {
"type": "string",
"description": "The ferrule part number.",
"nullable": true
},
"ferrulePartBrand": {
"type": "string",
"description": "The brand of the ferrule part.",
"nullable": true
},
"dieSize": {
"type": "string",
"description": "The die size.",
"nullable": true
},
"spacerRing": {
"type": "string",
"description": "The spacer ring.",
"nullable": true
},
"insertLength": {
"type": "object",
"properties": {
"value": {
"type": "number",
"format": "decimal",
"description": "The value of the insert length.",
"nullable": true
},
"unit": {
"type": "string",
"description": "The unit of the insert length.",
"nullable": true
}
}
},
"crimpDiam": {
"type": "object",
"properties": {
"value": {
"type": "number",
"format": "decimal",
"description": "The value of the crimp diameter.",
"nullable": true
},
"unit": {
"type": "string",
"description": "The unit of the crimp diameter.",
"nullable": true
},
"tolerance": {
"type": "number",
"format": "decimal",
"description": "The tolerance of the crimp diameter.",
"nullable": true
},
"tolerancePlus": {
"type": "number",
"format": "decimal",
"description": "The positive tolerance of the crimp diameter.",
"nullable": true
},
"toleranceMinus": {
"type": "number",
"format": "decimal",
"description": "The negative tolerance of the crimp diameter.",
"nullable": true
}
}
},
"crimpStretchPerEnd": {
"type": "object",
"properties": {
"value": {
"type": "number",
"format": "decimal",
"description": "The value of the crimp stretch per end.",
"nullable": true
},
"unit": {
"type": "string",
"description": "The unit of the crimp stretch per end.",
"nullable": true
}
}
},
"skiveExternal": {
"type": "object",
"properties": {
"value": {
"type": "number",
"format": "decimal",
"description": "The value of the external skive.",
"nullable": true
},
"unit": {
"type": "string",
"description": "The unit of the external skive.",
"nullable": true
}
}
},
"skiveInternal": {
"type": "object",
"properties": {
"value": {
"type": "number",
"format": "decimal",
"description": "The value of the internal skive.",
"nullable": true
},
"unit": {
"type": "string",
"description": "The unit of the internal skive.",
"nullable": true
}
}
},
"interlock": {
"type": "boolean",
"description": "The interlock status.",
"nullable": true
}
}
}
}
}
}';
const headers = {
'Content-Type':'application/json',
'Accept':'application/json'
};
fetch('https://goldleaf.app/api/v1/hoses/create',
{
method: 'POST',
body: inputBody,
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
POST /hoses/create
Create a hose
Creates a new hose for the organization with the given properties.
Body parameter
{
"type": "object",
"required": ["partNumber", "brand", "size"],
"properties": {
"partNumber": {
"type": "string",
"description": "The part number, must be a non-empty string."
},
"brand": {
"type": "string",
"description": "The brand of the part, must be a non-empty string."
},
"size": {
"type": "string",
"description": "The size of the part, must be a non-empty string."
},
"nominalHoseSize": {
"type": "string",
"description": "The nominal size of the hose.",
"nullable": true
},
"description": {
"type": "string",
"description": "The description of the part.",
"nullable": true
},
"colourHose": {
"type": "string",
"description": "The color of the hose.",
"nullable": true
},
"colourLayLine": {
"type": "string",
"description": "The color of the lay line.",
"nullable": true
},
"colourLayLineText": {
"type": "string",
"description": "The color of the lay line text.",
"nullable": true
},
"series": {
"type": "string",
"description": "The series of the part.",
"nullable": true
},
"innerDiamInch": {
"type": "string",
"description": "The inner diameter in inches.",
"nullable": true
},
"spec": {
"type": "string",
"description": "The specification of the part.",
"nullable": true
},
"saeSpec": {
"type": "string",
"description": "The SAE specification of the part.",
"nullable": true
},
"isoSpec": {
"type": "string",
"description": "The ISO specification of the part.",
"nullable": true
},
"DN": {
"type": "string",
"description": "The DN specification of the part.",
"nullable": true
},
"isoClass": {
"type": "string",
"description": "The ISO class of the part.",
"nullable": true
},
"isoGrade": {
"type": "string",
"description": "The ISO grade of the part.",
"nullable": true
},
"isoType": {
"type": "string",
"description": "The ISO type of the part.",
"nullable": true
},
"reinforcement": {
"type": "string",
"description": "The reinforcement of the part.",
"nullable": true
},
"construction": {
"type": "string",
"description": "The construction of the part.",
"nullable": true
},
"colour": {
"type": "string",
"description": "The color of the part.",
"nullable": true
},
"temperatureRange": {
"type": "string",
"description": "The temperature range of the part.",
"nullable": true
},
"cover": {
"type": "string",
"description": "The cover of the part.",
"nullable": true
},
"tube": {
"type": "string",
"description": "The tube of the part.",
"nullable": true
},
"generalApplications": {
"type": "string",
"description": "The general applications of the part.",
"nullable": true
},
"impulseCycles": {
"type": "string",
"description": "The impulse cycles of the part.",
"nullable": true
},
"maxTempAir": {
"type": "string",
"description": "The maximum temperature for air.",
"nullable": true
},
"material": {
"type": "string",
"description": "The material of the part.",
"nullable": true
},
"maxPressurePsi": {
"type": "number",
"format": "decimal",
"description": "The maximum pressure in PSI.",
"nullable": true
},
"outerDiamInch": {
"type": "number",
"format": "decimal",
"description": "The outer diameter in inches.",
"nullable": true
},
"reinforcementDiamInch": {
"type": "number",
"format": "decimal",
"description": "The reinforcement diameter in inches.",
"nullable": true
},
"minBendRadiusInch": {
"type": "number",
"format": "decimal",
"description": "The minimum bend radius in inches.",
"nullable": true
},
"WeightLbs": {
"type": "number",
"format": "decimal",
"description": "The weight in pounds.",
"nullable": true
},
"burstPressurePsi": {
"type": "number",
"format": "decimal",
"description": "The burst pressure in PSI.",
"nullable": true
},
"standardLength": {
"type": "array",
"items": {
"type": "string"
},
"description": "The standard lengths of the part.",
"nullable": true
},
"recommendedCouplingSeries": {
"type": "array",
"items": {
"type": "string"
},
"description": "The recommended coupling series for the part.",
"nullable": true
},
"minTemp": {
"type": "array",
"items": {
"type": "string"
},
"description": "The minimum temperatures for the part.",
"nullable": true
},
"maxTemp": {
"type": "array",
"items": {
"type": "string"
},
"description": "The maximum temperatures for the part.",
"nullable": true
},
"type": {
"type": "array",
"items": {
"type": "string"
},
"description": "The types of the part.",
"nullable": true
},
"crimpSpecs": {
"type": "array",
"items": {
"type": "object",
"required": ["couplingSeries", "couplingSeriesBrand"],
"properties": {
"couplingSeries": {
"type": "string",
"description": "The coupling series, must be a non-empty string."
},
"couplingSeriesBrand": {
"type": "string",
"description": "The brand of the coupling series, must be a non-empty string."
},
"ferrulePartNumber": {
"type": "string",
"description": "The ferrule part number.",
"nullable": true
},
"ferrulePartBrand": {
"type": "string",
"description": "The brand of the ferrule part.",
"nullable": true
},
"dieSize": {
"type": "string",
"description": "The die size.",
"nullable": true
},
"spacerRing": {
"type": "string",
"description": "The spacer ring.",
"nullable": true
},
"insertLength": {
"type": "object",
"properties": {
"value": {
"type": "number",
"format": "decimal",
"description": "The value of the insert length.",
"nullable": true
},
"unit": {
"type": "string",
"description": "The unit of the insert length.",
"nullable": true
}
}
},
"crimpDiam": {
"type": "object",
"properties": {
"value": {
"type": "number",
"format": "decimal",
"description": "The value of the crimp diameter.",
"nullable": true
},
"unit": {
"type": "string",
"description": "The unit of the crimp diameter.",
"nullable": true
},
"tolerance": {
"type": "number",
"format": "decimal",
"description": "The tolerance of the crimp diameter.",
"nullable": true
},
"tolerancePlus": {
"type": "number",
"format": "decimal",
"description": "The positive tolerance of the crimp diameter.",
"nullable": true
},
"toleranceMinus": {
"type": "number",
"format": "decimal",
"description": "The negative tolerance of the crimp diameter.",
"nullable": true
}
}
},
"crimpStretchPerEnd": {
"type": "object",
"properties": {
"value": {
"type": "number",
"format": "decimal",
"description": "The value of the crimp stretch per end.",
"nullable": true
},
"unit": {
"type": "string",
"description": "The unit of the crimp stretch per end.",
"nullable": true
}
}
},
"skiveExternal": {
"type": "object",
"properties": {
"value": {
"type": "number",
"format": "decimal",
"description": "The value of the external skive.",
"nullable": true
},
"unit": {
"type": "string",
"description": "The unit of the external skive.",
"nullable": true
}
}
},
"skiveInternal": {
"type": "object",
"properties": {
"value": {
"type": "number",
"format": "decimal",
"description": "The value of the internal skive.",
"nullable": true
},
"unit": {
"type": "string",
"description": "The unit of the internal skive.",
"nullable": true
}
}
},
"interlock": {
"type": "boolean",
"description": "The interlock status.",
"nullable": true
}
}
}
}
}
}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| body | body | object | true | none |
| » partNumber | body | string | true | The part number, must be a non-empty string. |
| » brand | body | string | true | The brand of the part, must be a non-empty string. |
| » size | body | string | true | The size of the part, must be a non-empty string. |
| » nominalHoseSize | body | string¦null | false | The nominal size of the hose. |
| » description | body | string¦null | false | The description of the part. |
| » colourHose | body | string¦null | false | The color of the hose. |
| » colourLayLine | body | string¦null | false | The color of the lay line. |
| » colourLayLineText | body | string¦null | false | The color of the lay line text. |
| » series | body | string¦null | false | The series of the part. |
| » innerDiamInch | body | string¦null | false | The inner diameter in inches. |
| » spec | body | string¦null | false | The specification of the part. |
| » saeSpec | body | string¦null | false | The SAE specification of the part. |
| » isoSpec | body | string¦null | false | The ISO specification of the part. |
| » DN | body | string¦null | false | The DN specification of the part. |
| » isoClass | body | string¦null | false | The ISO class of the part. |
| » isoGrade | body | string¦null | false | The ISO grade of the part. |
| » isoType | body | string¦null | false | The ISO type of the part. |
| » reinforcement | body | string¦null | false | The reinforcement of the part. |
| » construction | body | string¦null | false | The construction of the part. |
| » colour | body | string¦null | false | The color of the part. |
| » temperatureRange | body | string¦null | false | The temperature range of the part. |
| » cover | body | string¦null | false | The cover of the part. |
| » tube | body | string¦null | false | The tube of the part. |
| » generalApplications | body | string¦null | false | The general applications of the part. |
| » impulseCycles | body | string¦null | false | The impulse cycles of the part. |
| » maxTempAir | body | string¦null | false | The maximum temperature for air. |
| » material | body | string¦null | false | The material of the part. |
| » maxPressurePsi | body | number(decimal)¦null | false | The maximum pressure in PSI. |
| » outerDiamInch | body | number(decimal)¦null | false | The outer diameter in inches. |
| » reinforcementDiamInch | body | number(decimal)¦null | false | The reinforcement diameter in inches. |
| » minBendRadiusInch | body | number(decimal)¦null | false | The minimum bend radius in inches. |
| » WeightLbs | body | number(decimal)¦null | false | The weight in pounds. |
| » burstPressurePsi | body | number(decimal)¦null | false | The burst pressure in PSI. |
| » standardLength | body | [string]¦null | false | The standard lengths of the part. |
| » recommendedCouplingSeries | body | [string]¦null | false | The recommended coupling series for the part. |
| » minTemp | body | [string]¦null | false | The minimum temperatures for the part. |
| » maxTemp | body | [string]¦null | false | The maximum temperatures for the part. |
| » type | body | [string]¦null | false | The types of the part. |
| » crimpSpecs | body | [object] | false | none |
| »» couplingSeries | body | string | true | The coupling series, must be a non-empty string. |
| »» couplingSeriesBrand | body | string | true | The brand of the coupling series, must be a non-empty string. |
| »» ferrulePartNumber | body | string¦null | false | The ferrule part number. |
| »» ferrulePartBrand | body | string¦null | false | The brand of the ferrule part. |
| »» dieSize | body | string¦null | false | The die size. |
| »» spacerRing | body | string¦null | false | The spacer ring. |
| »» insertLength | body | object | false | none |
| »»» value | body | number(decimal)¦null | false | The value of the insert length. |
| »»» unit | body | string¦null | false | The unit of the insert length. |
| »» crimpDiam | body | object | false | none |
| »»» value | body | number(decimal)¦null | false | The value of the crimp diameter. |
| »»» unit | body | string¦null | false | The unit of the crimp diameter. |
| »»» tolerance | body | number(decimal)¦null | false | The tolerance of the crimp diameter. |
| »»» tolerancePlus | body | number(decimal)¦null | false | The positive tolerance of the crimp diameter. |
| »»» toleranceMinus | body | number(decimal)¦null | false | The negative tolerance of the crimp diameter. |
| »» crimpStretchPerEnd | body | object | false | none |
| »»» value | body | number(decimal)¦null | false | The value of the crimp stretch per end. |
| »»» unit | body | string¦null | false | The unit of the crimp stretch per end. |
| »» skiveExternal | body | object | false | none |
| »»» value | body | number(decimal)¦null | false | The value of the external skive. |
| »»» unit | body | string¦null | false | The unit of the external skive. |
| »» skiveInternal | body | object | false | none |
| »»» value | body | number(decimal)¦null | false | The value of the internal skive. |
| »»» unit | body | string¦null | false | The unit of the internal skive. |
| »» interlock | body | boolean¦null | false | The interlock status. |
Example responses
500 Response
{
"type": "string"
}
Responses
| Status | Meaning | Description | Schema |
|---|---|---|---|
| 201 | Created | the newly created hose | None |
| 500 | Internal Server Error | Server error | string |
