Skip to content

Commit 0976eb8

Browse files
authored
Documentation improvements (#15)
1 parent c649cee commit 0976eb8

File tree

4 files changed

+50
-8
lines changed

4 files changed

+50
-8
lines changed

README.md

Lines changed: 39 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,20 +15,52 @@ In order to use this library you need to have access to an Oracle Field Service
1515

1616
`npm install https://github.com/oracle-samples/ofs-proxy-js.git` (when installing directly from GitHub)
1717

18+
`npm install @ofs-users/proxy` (when installing from npm)
19+
1820
2. To use the library in your code:
1921

20-
`import {OFSPlugin} from "@ofs_users/proxy"`
22+
`import {OFS} from "@ofs-users/proxy"`
23+
24+
## Functions implemented (may not be complete)
2125

22-
## Functions implemented
26+
### Core: Activity Management
2327

24-
`getActivity(activityId)`: Get activity details
28+
`getActivities()`: Get existing activities
2529

2630
`updateActivity(activityId, activityData)`: Update activity details
2731

32+
`createActivity(activityData)`: Create activity
33+
34+
`deleteActivity(activityId)`: Delete activity
35+
36+
`updateActivity(activityId, activityData)`: Update activity details
37+
38+
### Core: Subscription Management
39+
2840
`getSubscriptions()`: Get existing subscriptions
2941

42+
### Core: User Management
43+
44+
`getUsers()`: Get existing users
45+
46+
`getUserDetails(userId)`: Get user details
47+
48+
`getAllUsers()`: Get all users
49+
50+
### Core: Plugin Management
51+
3052
`importPlugins(file?, data?)`: Import plugin by path or via an XML string
3153

54+
### Metadata: Property Management
55+
56+
`getProperties()`: Get existing properties
57+
58+
`getPropertyDetails(propertyId)`: Get property details
59+
60+
`updateProperty(propertyId, propertyData)`: Update property details
61+
62+
`createReplaceProperty(propertyData)`: Create or replace property
63+
3264
## Documentation and Examples
3365

3466
Please see the `docs/` directory for documentation and a simple example
@@ -37,8 +69,11 @@ Please see the `docs/` directory for documentation and a simple example
3769

3870
| Version | Comments |
3971
| ---------| ----------- |
40-
| 0.1| Added `getActivity`, `updateActivity`, `getSubscriptions` |
72+
| 0.1| Added `getActivityDetails`, `updateActivity`, `getSubscriptions` |
4173
| 1.1| Added `importPlugins` |
74+
| 1.2| Added `createActivity`, `deleteActivity` |
75+
| 1.6| Added `getUsers`, `getUserDetails`, `getAllUsers` |
76+
| 1.8| Added `getProperties`, `getPropertyDetails`, `updateProperty` `createReplaceProperty` |
4277

4378
## Contributing
4479

docs/README.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,17 @@
22

33
| Function | URL |
44
| ---------| ----------- |
5-
| `getActivity`| https://docs.oracle.com/en/cloud/saas/field-service/cxfsc/op-rest-ofsccore-v1-activities-activityid-get.html |
5+
| `getActivities`| https://docs.oracle.com/en/cloud/saas/field-service/cxfsc/op-rest-ofsccore-v1-activities-get.html |
6+
| `createActivity`| https://docs.oracle.com/en/cloud/saas/field-service/cxfsc/op-rest-ofsccore-v1-activities-post.html |
7+
| `deleteActivity`| https://docs.oracle.com/en/cloud/saas/field-service/cxfsc/op-rest-ofsccore-v1-activities-activityid-delete.html |
8+
| `getActivityDetails`| https://docs.oracle.com/en/cloud/saas/field-service/cxfsc/op-rest-ofsccore-v1-activities-activityid-get.html |
69
| `updateActivity`| https://docs.oracle.com/en/cloud/saas/field-service/cxfsc/op-rest-ofsccore-v1-activities-activityid-patch.html
710
| `getSubscriptions` | https://docs.oracle.com/en/cloud/saas/field-service/cxfsc/op-rest-ofsccore-v1-events-subscriptions-get.html
811
| `importPlugins` | https://docs.oracle.com/en/cloud/saas/field-service/cxfsc/op-rest-ofscmetadata-v1-plugins-custom-actions-import-post.html
12+
| `getProperties` | https://docs.oracle.com/en/cloud/saas/field-service/cxfsc/op-rest-ofscmetadata-v1-properties-get.html
13+
| `getPropertyDetails` | https://docs.oracle.com/en/cloud/saas/field-service/cxfsc/op-rest-ofscmetadata-v1-properties-label-get.html
14+
| `updateProperty` | https://docs.oracle.com/en/cloud/saas/field-service/cxfsc/op-rest-ofscmetadata-v1-properties-label-patch.html
15+
| `createReplaceProperty` | https://docs.oracle.com/en/cloud/saas/field-service/cxfsc/op-rest-ofscmetadata-v1-properties-label-put.html
916

1017
## Sample
1118

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
],
66
"name": "@ofs-users/proxy",
77
"type": "module",
8-
"version": "1.8.0",
8+
"version": "1.8.1",
99
"description": "A Javascript proxy to access Oracle Field Service via REST API",
1010
"main": "dist/ofs.es.js",
1111
"module": "dist/ofs.es.js",

0 commit comments

Comments
 (0)