Prepending 'SU:' to Actor in Getstream-io Feed Update
Asked Answered
G

1

6

Why do you have to prepending SU: to actor ID in a getstream-io feed update?

data = {'actor'  : 'SU:ronald',      
        'message': 'hello',          
        'object' : 'object',
        'verb'   : 'post'
        }

Without SU: I get the error: The policy "Don't impersonate other users" (900) blocked this request.

{'detail': 'The policy "Don\'t impersonate other users" (900) blocked this request, please consult the documentation https://getstream.io/docs/',
 'status_code': 403,
 'code': 17,
 'exception': 'NotAllowedException',
 'duration': '0.17ms'}
Gravante answered 29/7, 2020 at 0:8 Comment(0)
G
0

The answer I got from Stream.io support...

We are prefixing the userID within the Stream API with this. SU: prefix means stream user reference such that when you call enrich endpoints to read feeds, it will replace strings with referenced user object. Actor colon rule is for prefixes, and simply ignore rule for regular exact string match.

Gravante answered 6/3, 2022 at 0:38 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.