https://pypi.org/project/pypresence/
Для создания приглашения, по идее, нужны partyId и joinSecret:
from pypresence import Presence
p = Presence(APP_ID)
p.connect()
p.update(state="Black\N{BLACK STAR}Rock Shooter", large_image="brs", party_id="generic_party", join="some_random_hash")
# Return:
{'cmd': 'SET_ACTIVITY',
'data': {'state': 'Black★Rock Shooter',
'assets': {'large_image': ASSET_ID},
'party': {'id': 'generic_party'},
'secrets': {'join': 'some_random_hash'},
'name': 'B★RS Project',
'application_id': APP_ID,
'flags': 3,
'type': 0},
'evt': None,
'nonce': CUR_TIME}