Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could not generate for this schema #21

Open
dilipmurupala opened this issue Jun 12, 2015 · 0 comments
Open

Could not generate for this schema #21

dilipmurupala opened this issue Jun 12, 2015 · 0 comments

Comments

@dilipmurupala
Copy link

For below schema, it did not generate the sample json data . It is a valid schema but generating sample data gave a number of errors

{
"$schema": "http://json-schema.org/draft-04/schema#",
"note": "The schema has been generated, please do not modify it directly.",
"type": "object",
"properties": {
"apiClientId": {
"type": "string",
"pattern": "^[0-9]+$"
},
"systemGenerated": {
"type": "boolean",
"description": "Indicates whether this enquiry was not invoked by a customer but via some system process"
},
"user": {
"type": "object",
"properties": {
"accountId": {
"type": [
"string",
"null"
],
"pattern": "^[a-zA-Z0-9]{8}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{12}$",
"description": "Customer account identifier"
},
"ip": {
"type": "string",
"format": "ipv4",
"description": "IP address of the customer who generated the enquiry"
},
"source": {
"type": "string",
"description": "MSM traffic source code"
},
"userId": {
"type": "string",
"description": "MSM user identifier"
},
"anonymous": {
"type": [
"boolean",
"null"
],
"description": "Was this enquiry submitted without authentication"
},
"sessionId": {
"type": [
"string",
"null"
],
"description": "Deprecated field"
}
},
"additionalProperties": false,
"required": [
"accountId",
"source",
"userId"
]
},
"brandFilter": {
"type": [
"object",
"null"
],
"properties": {
"type": {
"type": "string",
"enum": [
"INCLUDE",
"EXCLUDE"
],
"description": "Brand filter used to limit brands searched for this enquiry"
},
"brands": {
"type": "array",
"items": {
"type": "string",
"description": "List of brand to take part oin the filter"
}
}
},
"additionalProperties": false
},
"payload": {
"type": "object",
"properties": {
"@Class": {
"type": "string"
},
"goal": {
"type": "array",
"items": {},
"description": "Which accounts are you interested in? Values should be one or more from following options - [cashIsa,fixedIsa, easyaccess, regular, notice, fixedbond, all]"
},
"userAgent": {
"type": "string"
},
"deviceType": {
"type": "integer"
},
"enquiryId": {
"type": "string"
},
"datetimeCreated": {
"type": "string",
"format": "Date/Time"
},
"savingsDetails": {
"type": "object",
"properties": {
"savingFor": {
"type": "string",
"enum": [
"date",
"amount",
"nothing"
],
"description": "Are you saving for anything in particular"
},
"savingEvent": {
"type": "string",
"enum": [
"wedding",
"holiday",
"house",
"car",
"travelling",
"other"
],
"description": "What are you saving towards"
},
"lumpSum": {
"type": "boolean",
"description": "Do you have a lump sump to start off with?"
},
"startingAmount": {
"type": "Integer",
"description": "How much do you have to start off with "
},
"access": {
"type": "string",
"description": "Do you need to access your savings"
},
"regularAdditions": {
"type": "string",
"enum": [
"yes",
"no",
"unknown"
],
"description": "Are you looking to add regular savings"
},
"existingIsa": {
"type": "boolean",
"description": "Do you have savings in an existing isa"
},
"transfercurrentIsa": {
"type": "boolean",
"description": "Would you like to transfer in these savings to a new account?"
},
"aimforDate": {
"type": "string",
"format": "Date/Time",
"description": "Which date are you aiming to save for"
},
"accessType": {
"type": "string",
"description": "How would you like to open and access the account."
},
"regularAmounts": {
"type": "Integer",
"description": "What regular deposits will you make?"
},
"currentSwitch": {
"type": "string",
"enum": [
"yes",
"no",
"maybe"
],
"description": "Are you willing to switch your Current account?"
}
},
"additionalProperties": false,
"required": [
"lumpSum",
"access"
]
},
"customerDetails": {
"type": "object",
"properties": {
"email": {
"type": "string",
"description": "Whats your email address?"
},
"firstName": {
"type": "string",
"description": "Whats your first name?"
},
"lastName": {
"type": "string",
"description": "Whats your last name?"
},
"dateofBirth": {
"type": "string",
"description": "Whats your Date of Birth?"
},
"postcode": {
"type": "string",
"description": "Whats your postcode"
},
"currentBank": {
"type": "string",
"enum": [
"barclays",
"natwest",
"halifax",
"lloyds",
"HSBC",
"BOS",
"Co-Op",
"firstdirect",
"nationwide",
"RBS",
"santander",
"chartered",
"tesco",
"TSB",
"other"
],
"description": "Who is your current account provider"
}
},
"additionalProperties": false,
"required": [
"email",
"firstName",
"lastName"
]
}
},
"additionalProperties": false,
"required": [
"@Class",
"goal",
"userAgent",
"deviceType",
"enquiryId",
"datetimeCreated"
]
}
},
"additionalProperties": false,
"required": [
"apiClientId",
"user",
"payload"
]
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant