MCPcopy Create free account
hub / github.com/GetStream/stream-js / post

Method post

src/personalization.ts:62–70  ·  view source on GitHub ↗

* Post data to personalization endpoint * * @method post * @memberof Personalization.prototype * @param {string} resource - personalized resource endpoint i.e "follow_recommendations" * @param {object} options - Additional options * @param {object} data - Data to send in the payloa

(resource: string, options: Record<string, string> = {}, data: UR = {})

Source from the content-addressed store, hash-verified

60 * @example client.personalization.post('follow_recommendations', {foo: 'bar', baz: 'qux'})
61 */
62 post(resource: string, options: Record<string, string> = {}, data: UR = {}) {
63 return this.client.post<PersonalizationAPIResponse<StreamFeedGenerics>>({
64 url: `${resource}/`,
65 serviceName: 'personalization',
66 qs: options,
67 body: data,
68 token: this.client.getPersonalizationToken(),
69 });
70 }
71
72 /**
73 * Delete metadata or activities

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected