onairos 0.0.7 → 0.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -48,13 +48,12 @@ Individual Request Information:
|
|
|
48
48
|
|
|
49
49
|
Then instantiate the Onairos object from the Onairos package - passing in your Onairos Developer ID and your Request Object
|
|
50
50
|
```jsx
|
|
51
|
-
<Onairos requestData={requestData} onairosID={onairosID}
|
|
51
|
+
<Onairos requestData={requestData} onairosID={onairosID} webpageName={webpageName} proofMode={proofMode} />
|
|
52
52
|
```
|
|
53
53
|
|
|
54
54
|
Onairos Object fields:
|
|
55
55
|
- `requestData` - Request Object - Json
|
|
56
56
|
- `onairosID` - App Assigned Onairos ID - String
|
|
57
|
-
- `access_token` - App Assigned Access Token - String
|
|
58
57
|
- `webpageName` - App Display Name - String
|
|
59
58
|
- `proofMode` - Wish to recieve ZK proof after recieving Data , default FALSE - boolean
|
|
60
59
|
|
|
@@ -97,6 +96,8 @@ Send a POST request to the API endpoint with a JSON payload containing a set of
|
|
|
97
96
|
- `category`: The category to which the content belongs (String) - required
|
|
98
97
|
- `img_url`: The URL of an image associated with the content (String) - optional
|
|
99
98
|
|
|
99
|
+
You should also send the access token as part of this request, from your **backend**
|
|
100
|
+
- `access_token` - App Assigned Access Token - String
|
|
100
101
|
Example JSON body for the POST request:
|
|
101
102
|
|
|
102
103
|
```json
|
|
@@ -116,7 +117,8 @@ Example JSON body for the POST request:
|
|
|
116
117
|
"text": "Example text input 3",
|
|
117
118
|
"category": "Example Category 3",
|
|
118
119
|
"img_url": "http://example.com/image3.jpg"
|
|
119
|
-
}
|
|
120
|
+
},
|
|
121
|
+
"AccessToken":"access_token"
|
|
120
122
|
}
|
|
121
123
|
// Additional entries can be added here
|
|
122
124
|
|
|
@@ -210,8 +212,8 @@ function App() {
|
|
|
210
212
|
type:"Personality",
|
|
211
213
|
descriptions:"Insight into your Interests",
|
|
212
214
|
reward:"2 USDC"
|
|
213
|
-
}
|
|
214
|
-
|
|
215
|
+
},
|
|
216
|
+
AccessToken:access_token
|
|
215
217
|
};
|
|
216
218
|
useEffect(() => {
|
|
217
219
|
window.addEventListener('message', UseAPIURL);
|