Skip to content

Commit

Permalink
done
Browse files Browse the repository at this point in the history
  • Loading branch information
deploy.sh committed Mar 23, 2018
1 parent a9d549f commit b5abec2
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 187 deletions.
54 changes: 5 additions & 49 deletions source/includes/_api.md
Original file line number Diff line number Diff line change
Expand Up @@ -441,24 +441,13 @@ curl "https://[GOODCOP_URL]/v1/api/{apiID}/rule"
```json
{
"id": 5643625413214208,
"name": "api test",
"description": "this is test api",
"rules": [
{
"verb": "GET",
"path": "/organizations/5746055551385600/*",
"effect": true
}
],
"meta": "test api",
"apiKeys": [
{
"name": "default",
"value": "asZ7nYKajsIl8RqtYYK-oyS2MC_6EKMYXMCDq0J7FfQ="
}
],
"productId": 6308443803615232
]
}
```

Expand Down Expand Up @@ -557,24 +546,7 @@ curl "https://[GOODCOP_URL]/v1/api/{apiID}/meta"
```json
{
"id": 5643625413214208,
"name": "api test",
"description": "this is test api",
"rules": [
{
"verb": "GET",
"path": "/organizations/5746055551385600/*",
"effect": true
}
],
"meta": "updated api meta",
"apiKeys": [
{
"name": "default",
"value": "asZ7nYKajsIl8RqtYYK-oyS2MC_6EKMYXMCDq0J7FfQ="
}
],
"productId": 6308443803615232
"meta": "updated api meta"
}
```

Expand Down Expand Up @@ -624,24 +596,8 @@ curl "https://[GOODCOP_URL]/v1/api/{apiID}/meta"
```json
{
"id": 5643625413214208,
"name": "api test",
"description": "this is test api",
"rules": [
{
"verb": "GET",
"path": "/organizations/5746055551385600/*",
"effect": true
}
],
"meta": "",
"apiKeys": [
{
"name": "default",
"value": "asZ7nYKajsIl8RqtYYK-oyS2MC_6EKMYXMCDq0J7FfQ="
}
],
"productId": 6308443803615232

"meta": ""
}
```

Expand All @@ -662,7 +618,7 @@ apiID | required | string | Valid api identifier

### Returns

Returns api object with no metadata. If invalid api ID or any other backend failures an appropriate error message will be returned with an error code associated with it.
Returns meta string no metadata. If invalid api ID or any other backend failures an appropriate error message will be returned with an error code associated with it.

### Error Messages

Expand Down
25 changes: 2 additions & 23 deletions source/includes/_group.md
Original file line number Diff line number Diff line change
Expand Up @@ -714,28 +714,7 @@ curl "https://[GOODCOP_URL]/v1/group/5717800035287040/meta"
```json
{
"groupId": 5717800035287040,
"name": "admin",
"description": "",
"rules": [
{
"verb": "GET",
"path": "/credentials/5687539843203072",
"effect": true
},
{
"verb": "PUT",
"path": "/credentials/5687539843203072",
"effect": true
},
{
"verb": "DELETE",
"path": "/credentials/5687539843203072",
"effect": true
}
],
"meta": "",
"productId": 5750501782061056
"meta": ""
}

```
Expand All @@ -761,7 +740,7 @@ groupID | required | string | Valid group identifier

### Returns

Returns group object with no metadata. If invalid group ID or any other backend failures an appropriate error message will be returned with an error code associated with it.
Returns meta string with no metadata. If invalid group ID or any other backend failures an appropriate error message will be returned with an error code associated with it.

### Error Messages

Expand Down
2 changes: 1 addition & 1 deletion source/includes/_org.md
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@ orgID | required | string | Valid org identifier

### Returns

Returns updated meta string. If invalid org ID or any other backend failures an appropriate error message will be returned with an error code associated with it.
Returns meta string with no metadata. If invalid org ID or any other backend failures an appropriate error message will be returned with an error code associated with it.

### Error Messages

Expand Down
4 changes: 2 additions & 2 deletions source/includes/_product.md
Original file line number Diff line number Diff line change
Expand Up @@ -501,7 +501,7 @@ curl "https://[GOODCOP_URL]/v1/product/5178306911535104/meta"
```json
{
"message": "meta deleted successfully"
"meta": ""
}
```

Expand All @@ -523,7 +523,7 @@ productID | required | string | Valid product identifier

### Returns

Returns success message on succesfull deletion of meta. If invalid product ID or any other backend failures an appropriate error message will be returned with an error code associated with it.
Returns meta string with no metadata. If invalid product ID or any other backend failures an appropriate error message will be returned with an error code associated with it.

### Error Messages

Expand Down
84 changes: 8 additions & 76 deletions source/includes/_tenant.md
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ curl "https://[GOODCOP_URL]/v1/tenant/{tenantID}/rule"
```json
{
"Rules": [
"rules": [
{
"verb": "GET",
"path": "/organizations/5746055551385600/*",
Expand Down Expand Up @@ -404,18 +404,13 @@ curl "https://[GOODCOP_URL]/v1/tenant/{tenantID}/rule"
```json
{
"id": 5996636694118400,
"name": "test tenant",
"apiId": 5916827746041856,
"rules": [
{
"verb": "GET",
"path": "/organizations/5746055551385600/*",
"effect": true
}
],
"meta": "",
"secrets": "{\"email\":\"mail@gmail.com\"}"
]
}
```

Expand All @@ -442,7 +437,7 @@ tenantID | required | string | Valid tenant identifier

### Returns

Returns tenant object with updated rules. If invalid tenant ID or any other backend failures an appropriate error message will be returned with an error code associated with it.
Returns updated rules. If invalid tenant ID or any other backend failures an appropriate error message will be returned with an error code associated with it.

### Error Messages

Expand Down Expand Up @@ -471,28 +466,7 @@ curl "https://[GOODCOP_URL]/v1/tenant/{tenantID}/secret"
```json
{
"id": 5996636694118400,
"name": "test api",
"apiId": 5916827746041856,
"rules": [
{
"verb": "GET",
"path": "/organizations/5746055551385600/*",
"effect": true
},
{
"verb": "PUT",
"path": "/organizations/5162157834502144/*",
"effect": true
},
{
"verb": "POST",
"path": "/organizations/5162157834502144/*",
"effect": true
}
],
"meta": "api meta",
"secrets": "{\"email\":\"mail@gmail.com\"}"
"message":"Secrets updated"
}
```

Expand All @@ -517,7 +491,7 @@ tenantID | required | string | Valid tenant identifier

### Returns

Returns updated secrets in the tenant. If invalid tenant ID or any other backend failures an appropriate error message will be returned with an error code associated with it.
Returns success message. If invalid tenant ID or any other backend failures an appropriate error message will be returned with an error code associated with it.

### Error Messages

Expand Down Expand Up @@ -640,28 +614,7 @@ curl "https://[GOODCOP_URL]/v1/tenant/{tenantID}/meta"
```json
{
"id": 5996636694118400,
"name": "test tenant",
"apiId": 5916827746041856,
"rules": [
{
"verb": "GET",
"path": "/organizations/5746055551385600/*",
"effect": true
},
{
"verb": "PUT",
"path": "/organizations/5162157834502144/*",
"effect": true
},
{
"verb": "POST",
"path": "/organizations/5162157834502144/*",
"effect": true
}
],
"meta": "updated tenant meta",
"secrets": "{\"email\":\"mail@gmail.com\"}"
"meta": "updated tenant meta"
}
```

Expand All @@ -686,7 +639,7 @@ tenantID | required | string | Valid tenant identifier

### Returns

Returns updated tenant object with updated string. If invalid tenant ID or any other backend failures an appropriate error message will be returned with an error code associated with it.
Returns updated meta string. If invalid tenant ID or any other backend failures an appropriate error message will be returned with an error code associated with it.

### Error Messages

Expand Down Expand Up @@ -714,28 +667,7 @@ curl "https://[GOODCOP_URL]/v1/tenant/{tenantID}/meta"
```json
{
"id": 5996636694118400,
"name": "test tenant",
"apiId": 5916827746041856,
"rules": [
{
"verb": "GET",
"path": "/organizations/5746055551385600/*",
"effect": true
},
{
"verb": "PUT",
"path": "/organizations/5162157834502144/*",
"effect": true
},
{
"verb": "POST",
"path": "/organizations/5162157834502144/*",
"effect": true
}
],
"meta": "",
"secrets": "{\"email\":\"mail@gmail.com\"}"
}
```

Expand All @@ -755,7 +687,7 @@ tenantID | required | string | Valid tenant identifier

### Returns

Returns tenant object with no metadata. If invalid tenant ID or any other backend failures an appropriate error message will be returned with an error code associated with it.
Returns meta with no metadata. If invalid tenant ID or any other backend failures an appropriate error message will be returned with an error code associated with it.

### Error Messages

Expand Down
40 changes: 4 additions & 36 deletions source/includes/_user.md
Original file line number Diff line number Diff line change
Expand Up @@ -1020,8 +1020,6 @@ curl "https://[GOODCOP_URL]/v1/user/test_oio4205c7-4139-4e14-a0d0-c5932ad99e9a/r
```json
{
"userId": "test_oio4205c7-4139-4e14-a0d0-c5932ad99e9a",
"email": "test@mail.com",
"rules": [
{
"verb": "GET",
Expand All @@ -1038,21 +1036,7 @@ curl "https://[GOODCOP_URL]/v1/user/test_oio4205c7-4139-4e14-a0d0-c5932ad99e9a/r
"path": "/credentials/5687539843203072",
"effect": true
}
],
"groups": [
5717800035287040,
5664530495438848,
],
"meta": "storing test meta info",
"devicetokens": [
{
"token": "TVzm6SDRY5i5lpXgrsNYxok9zgJODJsA7VB15yl2qvUeTG_n3HYmEHaYwt73K-1vGpsUTV18wssDyEWGHdInPw==",
"deviceid": ""
}
],
"verified": false,
"createdAt": "0001-01-01T05:21:10+05:21",
"updatedAt": "2018-03-22T12:08:02.07777+05:30"
]
}
```

Expand All @@ -1076,7 +1060,7 @@ userID | required | string | Valid user identifier

### Returns

Returns user object with updated rules. If invalid user ID or any other backend failures an appropriate error message will be returned with an error code associated with it.
Returns updated rules. If invalid user ID or any other backend failures an appropriate error message will be returned with an error code associated with it.

### Error Messages

Expand Down Expand Up @@ -1105,8 +1089,6 @@ curl "https://[GOODCOP_URL]/v1/user/test_oio4205c7-4139-4e14-a0d0-c5932ad99e9a/r
```json
{
"userId": "test_oio4205c7-4139-4e14-a0d0-c5932ad99e9a",
"email": "test@mail.com",
"rules": [
{
"verb": "PUT",
Expand All @@ -1118,21 +1100,7 @@ curl "https://[GOODCOP_URL]/v1/user/test_oio4205c7-4139-4e14-a0d0-c5932ad99e9a/r
"path": "/credentials/5687539843203072",
"effect": true
}
],
"groups": [
5717800035287040,
5664530495438848,
],
"meta": "storing test meta info",
"devicetokens": [
{
"token": "TVzm6SDRY5i5lpXgrsNYxok9zgJODJsA7VB15yl2qvUeTG_n3HYmEHaYwt73K-1vGpsUTV18wssDyEWGHdInPw==",
"deviceid": ""
}
],
"verified": false,
"createdAt": "0001-01-01T05:21:10+05:21",
"updatedAt": "2018-03-22T12:08:02.07777+05:30"
]
}
```

Expand All @@ -1150,7 +1118,7 @@ userID | required | string | Valid user identifier

### Returns

Returns user object with updated rules. If invalid user ID or any other backend failures an appropriate error message will be returned with an error code associated with it.
Returns updated rules. If invalid user ID or any other backend failures an appropriate error message will be returned with an error code associated with it.

### Error Messages

Expand Down

0 comments on commit b5abec2

Please sign in to comment.