Skip to content

Commit

Permalink
V1.4
Browse files Browse the repository at this point in the history
  • Loading branch information
keitharm committed Jul 5, 2022
1 parent 2a4f928 commit f2b0495
Show file tree
Hide file tree
Showing 4 changed files with 73 additions and 68 deletions.
4 changes: 2 additions & 2 deletions api/.nextRelease/data/US/inject.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ module.exports = (inc, contents) => {
const pic = contents.picture;
delete contents.picture;

include(inc, contents, 'phone', '(' + random(4, 1) + random(3, 2) + ') ' + random(4, 1) + random(3, 2) + '-' + random(3, 4));
include(inc, contents, 'cell', '(' + random(4, 1) + random(3, 2) + ') ' + random(4, 1) + random(3, 2) + '-' + random(3, 4));
include(inc, contents, 'phone', '(' + random(5, 1) + random(3, 2) + ') ' + random(5, 1) + random(3, 2) + '-' + random(3, 4));
include(inc, contents, 'cell', '(' + random(5, 1) + random(3, 2) + ') ' + random(5, 1) + random(3, 2) + '-' + random(3, 4));
include(inc, contents, 'id', () => {
const checkSSN = (ssn) => {
const regex = new RegExp("^(?!219-09-9999|078-05-1120)(?!666|000|9\\d{2})\\d{3}-(?!00)\\d{2}-(?!0{4})\\d{4}$");
Expand Down
4 changes: 2 additions & 2 deletions api/1.4/data/US/inject.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ module.exports = (inc, contents) => {
const pic = contents.picture;
delete contents.picture;

include(inc, contents, 'phone', '(' + random(4, 1) + random(3, 2) + ') ' + random(4, 1) + random(3, 2) + '-' + random(3, 4));
include(inc, contents, 'cell', '(' + random(4, 1) + random(3, 2) + ') ' + random(4, 1) + random(3, 2) + '-' + random(3, 4));
include(inc, contents, 'phone', '(' + random(5, 1) + random(3, 2) + ') ' + random(5, 1) + random(3, 2) + '-' + random(3, 4));
include(inc, contents, 'cell', '(' + random(5, 1) + random(3, 2) + ') ' + random(5, 1) + random(3, 2) + '-' + random(3, 4));
include(inc, contents, 'id', () => {
const checkSSN = (ssn) => {
const regex = new RegExp("^(?!219-09-9999|078-05-1120)(?!666|000|9\\d{2})\\d{3}-(?!00)\\d{2}-(?!0{4})\\d{4}$");
Expand Down
67 changes: 34 additions & 33 deletions views/pages/documentation.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -58,66 +58,67 @@ $.ajax({
{
"results": [
{
"gender": "<span>male</span>",
"gender": "<span>female</span>",
"name": {
"title": "<span>mr</span>",
"first": "<span>brad</span>",
"last": "<span>gibson</span>"
"title": "<span>Miss</span>",
"first": "<span>Jennie</span>",
"last": "<span>Nichols</span>"
},
"location": {
"street": {
"number": "<span>9278</span>",
"name": "<span>new road</span>",
},
"city": "<span>kilcoole</span>",
"state": "<span>waterford</span>",
"postcode": "<span>93027</span>",
"number": <span>8929</span>,
"name": "<span>Valwood Pkwy</span>",
},
"city": "<span>Billings</span>",
"state": "<span>Michigan</span>",
"country": "<span>United States</span>",
"postcode": "<span>63104</span>",
"coordinates": {
"latitude": "<span>20.9267</span>",
"longitude": "<span>-7.9310</span>"
"latitude": "<span>-69.8246</span>",
"longitude": "<span>134.8719</span>"
},
"timezone": {
"offset": "<span>-3:30</span>",
"description": "<span>Newfoundland</span>"
"offset": "<span>+9:30</span>",
"description": "<span>Adelaide, Darwin</span>"
}
},
"email": "<span>brad.gibson@example.com</span>",
"email": "<span>jennie.nichols@example.com</span>",
"login": {
"uuid": "<span>155e77ee-ba6d-486f-95ce-0e0c0fb4b919</span>",
"username": "<span>silverswan131</span>",
"password": "<span>firewall</span>",
"salt": "<span>TQA1Gz7x</span>",
"md5": "<span>dc523cb313b63dfe5be2140b0c05b3bc</span>",
"sha1": "<span>7a4aa07d1bedcc6bcf4b7f8856643492c191540d</span>",
"sha256": "<span>74364e96174afa7d17ee52dd2c9c7a4651fe1254f471a78bda0190135dcd3480</span>"
"uuid": "<span>7a0eed16-9430-4d68-901f-c0d4c1c3bf00</span>",
"username": "<span>yellowpeacock117</span>",
"password": "<span>addison</span>",
"salt": "<span>sld1yGtd</span>",
"md5": "<span>ab54ac4c0be9480ae8fa5e9e2a5196a3</span>",
"sha1": "<span>edcf2ce613cbdea349133c52dc2f3b83168dc51b</span>",
"sha256": "<span>48df5229235ada28389b91e60a935e4f9b73eb4bdb855ef9258a1751f10bdc5d</span>"
},
"dob": {
"date": "<span>1993-07-20T09:44:18.674Z</span>",
"age": <span>26</span>
"date": "<span>1992-03-08T15:13:16.688Z</span>",
"age": <span>30</span>
},
"registered": {
"date": "<span>2002-05-21T10:59:49.966Z</span>",
"age": <span>17</span>
"date": "<span>2007-07-09T05:51:59.390Z</span>",
"age": <span>14</span>
},
"phone": "<span>011-962-7516</span>",
"cell": "<span>081-454-0666</span>",
"phone": "<span>(272) 790-0888</span>",
"cell": "<span>(489) 330-2385</span>",
"id": {
"name": "<span>PPS</span>",
"value": "<span>0390511T</span>"
"name": "<span>SSN</span>",
"value": "<span>405-88-3636</span>"
},
"picture": {
"large": "<span>https://randomuser.me/api/portraits/men/75.jpg</span>",
"medium": "<span>https://randomuser.me/api/portraits/med/men/75.jpg</span>",
"thumbnail": "<span>https://randomuser.me/api/portraits/thumb/men/75.jpg</span>"
},
"nat": "<span>IE</span>"
"nat": "<span>US</span>"
}
],
"info": {
"seed": "<span>fea8be3e64777240</span>",
"seed": "<span>56d27f4a53bd5441</span>",
"results": <span>1</span>,
"page": <span>1</span>,
"version": "<span>1.3</span>"
"version": "<span>1.4</span>"
}
}
</pre>
Expand Down
66 changes: 35 additions & 31 deletions views/pages/index.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -77,63 +77,67 @@ $.ajax({
{
"results": [
{
"gender": "<span>male</span>",
"gender": "<span>female</span>",
"name": {
"title": "<span>mr</span>",
"first": "<span>brad</span>",
"last": "<span>gibson</span>"
"title": "<span>Miss</span>",
"first": "<span>Jennie</span>",
"last": "<span>Nichols</span>"
},
"location": {
"street": "<span>9278 new road</span>",
"city": "<span>kilcoole</span>",
"state": "<span>waterford</span>",
"postcode": "<span>93027</span>",
"street": {
"number": <span>8929</span>,
"name": "<span>Valwood Pkwy</span>",
},
"city": "<span>Billings</span>",
"state": "<span>Michigan</span>",
"country": "<span>United States</span>",
"postcode": "<span>63104</span>",
"coordinates": {
"latitude": "<span>20.9267</span>",
"longitude": "<span>-7.9310</span>"
"latitude": "<span>-69.8246</span>",
"longitude": "<span>134.8719</span>"
},
"timezone": {
"offset": "<span>-3:30</span>",
"description": "<span>Newfoundland</span>"
"offset": "<span>+9:30</span>",
"description": "<span>Adelaide, Darwin</span>"
}
},
"email": "<span>brad.gibson@example.com</span>",
"email": "<span>jennie.nichols@example.com</span>",
"login": {
"uuid": "<span>155e77ee-ba6d-486f-95ce-0e0c0fb4b919</span>",
"username": "<span>silverswan131</span>",
"password": "<span>firewall</span>",
"salt": "<span>TQA1Gz7x</span>",
"md5": "<span>dc523cb313b63dfe5be2140b0c05b3bc</span>",
"sha1": "<span>7a4aa07d1bedcc6bcf4b7f8856643492c191540d</span>",
"sha256": "<span>74364e96174afa7d17ee52dd2c9c7a4651fe1254f471a78bda0190135dcd3480</span>"
"uuid": "<span>7a0eed16-9430-4d68-901f-c0d4c1c3bf00</span>",
"username": "<span>yellowpeacock117</span>",
"password": "<span>addison</span>",
"salt": "<span>sld1yGtd</span>",
"md5": "<span>ab54ac4c0be9480ae8fa5e9e2a5196a3</span>",
"sha1": "<span>edcf2ce613cbdea349133c52dc2f3b83168dc51b</span>",
"sha256": "<span>48df5229235ada28389b91e60a935e4f9b73eb4bdb855ef9258a1751f10bdc5d</span>"
},
"dob": {
"date": "<span>1993-07-20T09:44:18.674Z</span>",
"age": <span>26</span>
"date": "<span>1992-03-08T15:13:16.688Z</span>",
"age": <span>30</span>
},
"registered": {
"date": "<span>2002-05-21T10:59:49.966Z</span>",
"age": <span>17</span>
"date": "<span>2007-07-09T05:51:59.390Z</span>",
"age": <span>14</span>
},
"phone": "<span>011-962-7516</span>",
"cell": "<span>081-454-0666</span>",
"phone": "<span>(272) 790-0888</span>",
"cell": "<span>(489) 330-2385</span>",
"id": {
"name": "<span>PPS</span>",
"value": "<span>0390511T</span>"
"name": "<span>SSN</span>",
"value": "<span>405-88-3636</span>"
},
"picture": {
"large": "<span>https://randomuser.me/api/portraits/men/75.jpg</span>",
"medium": "<span>https://randomuser.me/api/portraits/med/men/75.jpg</span>",
"thumbnail": "<span>https://randomuser.me/api/portraits/thumb/men/75.jpg</span>"
},
"nat": "<span>IE</span>"
"nat": "<span>US</span>"
}
],
"info": {
"seed": "<span>fea8be3e64777240</span>",
"seed": "<span>56d27f4a53bd5441</span>",
"results": <span>1</span>,
"page": <span>1</span>,
"version": "<span>1.3</span>"
"version": "<span>1.4</span>"
}
}
</pre>
Expand Down

0 comments on commit f2b0495

Please sign in to comment.