Skip to content

Server Callbacks

All callbacks are registered via lib.callback.register (ox_lib) and invoked from the client with lib.callback. The first parameter is always source (injected by ox_lib).

Phone

CallbackParametersReturnDescription
gcphone:getPhoneDatasourcetableGet initial phone data for the player.
gcphone:phone:getSetupStatesourcetableGet the phone setup/onboarding state.
gcphone:phone:completeSetupsource, data: tabletableComplete phone initial setup.
gcphone:phone:verifyPinsource, data: tabletableVerify the phone lock PIN.
gcphone:phone:reportImeiViewedsource, data: tabletableReport that the IMEI was viewed (audit).
gcphone:setWallpapersource, data: tablebooleanSet the phone wallpaper.
gcphone:setRingtonesource, data: tablebooleanSet the ringtone.
gcphone:setCallRingtonesource, data: tablebooleanSet the call ringtone.
gcphone:setNotificationTonesource, data: tablebooleanSet the notification tone.
gcphone:setMessageTonesource, data: tablebooleanSet the message tone.
gcphone:setVolumesource, data: tablebooleanSet the phone volume.
gcphone:setLockCodesource, data: tablebooleanSet or change the lock code.
gcphone:factoryResetPhonesourcebooleanFactory reset the phone (wipes all data).
gcphone:setThemesource, data: tablebooleanSet the phone theme.
gcphone:setLanguagesource, data: tablebooleanSet the phone language.
gcphone:setAudioProfilesource, data: tablebooleanSet the audio profile.
gcphone:getAppLayoutsourcetableGet the app layout/order.
gcphone:setAppLayoutsource, layout: tablebooleanSet the app layout/order.
gcphone:getPhoneMetadatasource, phoneId: integertableGet metadata for a specific phone (dropped phone context).

Contacts

CallbackParametersReturnDescription
gcphone:getContactssourcetable[]Get all contacts for the player.
gcphone:addContactsource, data: tabletableAdd a new contact.
gcphone:updateContactsource, data: tabletableUpdate an existing contact.
gcphone:deleteContactsource, contactId: integerbooleanDelete a contact.
gcphone:toggleFavoritesource, contactId: integerbooleanToggle contact favorite status.
gcphone:shareContactsource, data: tablebooleanShare a contact via SMS.
gcphone:acceptSharedContactsource, data: tabletableAccept a shared contact.

Messages

CallbackParametersReturnDescription
gcphone:getMessagessourcetable[]Get all message threads.
gcphone:getConversationsource, phoneNumber: stringtable[]Get messages in a conversation.
gcphone:sendMessagesource, data: tabletableSend an SMS message.
gcphone:deleteMessagesource, messageId: integerbooleanDelete a single message.
gcphone:deleteConversationsource, phoneNumber: stringbooleanDelete an entire conversation.
gcphone:markAsReadsource, phoneNumber: stringbooleanMark a conversation as read.
gcphone:getUnreadCountsourceintegerGet unread message count.
gcphone:setAutoReplysource, data: tablebooleanSet auto-reply settings.
gcphone:getAutoReplysourcetableGet current auto-reply settings.

WaveChat (Group Messages)

CallbackParametersReturnDescription
gcphone:wavechatGetGroupssourcetable[]Get all group chats.
gcphone:wavechatGetInvitessourcetable[]Get pending group invites.
gcphone:wavechatCreateGroupsource, data: tabletableCreate a new group chat.
gcphone:wavechatGetGroupMessagessource, data: tabletable[]Get messages in a group.
gcphone:wavechatRespondInvitesource, data: tablebooleanAccept or reject a group invite.
gcphone:wavechatSendGroupMessagesource, data: tabletableSend a message to a group.
gcphone:wavechatGetStatusessourcetable[]Get WaveChat status updates.
gcphone:wavechatCreateStatussource, data: tabletableCreate a status update.
gcphone:wavechatMarkStatusViewedsource, statusId: integerbooleanMark a status as viewed.

Calls

CallbackParametersReturnDescription
gcphone:getCallHistorysourcetable[]Get call history.
gcphone:deleteCallHistorysource, phoneNumber: stringbooleanDelete call history for a number.
gcphone:clearCallHistorysourcebooleanClear all call history.
gcphone:startCallsource, data: tabletableInitiate a phone call.
gcphone:acceptCallsource, data: tabletableAccept an incoming call.
gcphone:emergencySOSsourcetableTrigger an emergency SOS.

Bank

CallbackParametersReturnDescription
gcphone:getBankBalancesourcetableGet the player's bank balance.
gcphone:getBankTransactionssourcetable[]Get bank transaction history.
gcphone:transferMoneysource, data: tabletableTransfer money to another player.
gcphone:getContactsForTransfersourcetable[]Get contacts available for bank transfer.

Wallet

CallbackParametersReturnDescription
gcphone:wallet:getStatesourcetableGet full wallet state (balance, cards).
gcphone:wallet:addCardsource, data: tabletableAdd a card to the wallet.
gcphone:wallet:removeCardsource, data: tablebooleanRemove a card from the wallet.
gcphone:wallet:transfersource, data: tabletableTransfer money via wallet.
gcphone:wallet:proximityTransfersource, data: tabletableProximity-based wallet transfer.
gcphone:wallet:createRequestsource, data: tabletableCreate a payment request.
gcphone:wallet:getPendingRequestssourcetable[]Get pending payment requests.
gcphone:wallet:respondRequestsource, data: tabletableAccept or reject a payment request.
gcphone:wallet:createInvoicesource, data: tabletableCreate an invoice.
gcphone:wallet:respondInvoicesource, data: tabletableRespond to an invoice.
gcphone:wallet:createNfcInvoicesource, data: tabletableCreate an NFC invoice.
gcphone:wallet:respondNfcInvoicesource, data: tabletableRespond to an NFC invoice.
CallbackParametersReturnDescription
gcphone:getGallerysourcetable[]Get all gallery photos.
gcphone:savePhotosource, data: tabletableSave a photo to gallery.
gcphone:deletePhotosource, photoId: integerbooleanDelete a photo.
gcphone:setPhotoAsWallpapersource, data: tablebooleanSet a photo as the wallpaper.
gcphone:gallery:shareNfcsource, data: tabletableShare a photo via NFC.

Snap (Social Media)

CallbackParametersReturnDescription
gcphone:snap:getAccountsourcetableGet the Snap account for the player.
gcphone:snap:createAccountsource, data: tabletableCreate a new Snap account.
gcphone:snap:updateAccountsource, data: tabletableUpdate Snap account profile.
gcphone:snap:getFeedsource, data: tabletable[]Get the Snap feed (paginated).
gcphone:snap:getStoriessourcetable[]Get stories.
gcphone:snap:publishPostsource, data: tabletablePublish a new Snap post.
gcphone:snap:publishStorysource, data: tabletablePublish a new story.
gcphone:snap:toggleLikesource, data: tablebooleanToggle like on a post.
gcphone:snap:deletePostsource, postId: integerbooleanDelete a post.
gcphone:snap:deleteStorysource, storyId: integerbooleanDelete a story.
gcphone:snap:followsource, data: tabletableFollow/unfollow a user.
gcphone:snap:getProfilesource, data: tabletableGet a user profile.
gcphone:snap:getDiscoverAccountssource, data: tabletable[]Discover accounts to follow.
gcphone:snap:getDiscoverFeedsource, data: tabletable[]Get the discover feed.
gcphone:snap:getPendingFollowRequestssourcetable[]Get pending follow requests.
gcphone:snap:getSentFollowRequestssourcetable[]Get sent follow requests.
gcphone:snap:respondFollowRequestsource, data: tablebooleanAccept/reject a follow request.
gcphone:snap:cancelFollowRequestsource, data: tablebooleanCancel a sent follow request.
gcphone:snap:startLivesourcetableStart a Snap live stream.
gcphone:snap:endLivesource, postId: integerbooleanEnd a Snap live stream.
gcphone:snap:getLiveStreamssourcetable[]Get active live streams.
gcphone:snap:joinLivesource, data: tabletableJoin a live stream.
gcphone:snap:leaveLivesource, data: tablebooleanLeave a live stream.
gcphone:snap:sendLiveMessagesource, data: tabletableSend a live stream message.
gcphone:snap:sendLiveReactionsource, data: tablebooleanSend a live stream reaction.
gcphone:snap:removeLiveMessagesource, data: tablebooleanRemove a live stream message.
gcphone:snap:muteLiveUsersource, data: tablebooleanMute a user in a live stream.
gcphone:snap:getLiveAudioSessionsource, data: tabletableGet live audio session info.

Clips

CallbackParametersReturnDescription
gcphone:clips:getAccountsourcetableGet the Clips account.
gcphone:clips:createAccountsource, data: tabletableCreate a Clips account.
gcphone:clips:updateAccountsource, data: tabletableUpdate the Clips account.
gcphone:clips:getFeedsource, data: tabletable[]Get the Clips feed.
gcphone:clips:getMyClipssource, data: tabletable[]Get the player's own clips.
gcphone:clips:publishsource, data: tabletablePublish a new clip.
gcphone:clips:deletePostsource, postId: integerbooleanDelete a clip.
gcphone:clips:toggleLikesource, data: tablebooleanToggle like on a clip.
gcphone:clips:getCommentssource, data: tabletable[]Get comments on a clip.
gcphone:clips:addCommentsource, data: tabletableAdd a comment to a clip.
gcphone:clips:deleteCommentsource, data: tablebooleanDelete a comment from a clip.

Chirp (Twitter-like)

CallbackParametersReturnDescription
gcphone:chirp:getAccountsourcetableGet the Chirp account.
gcphone:chirp:createAccountsource, data: tabletableCreate a Chirp account.
gcphone:chirp:updateAccountsource, data: tabletableUpdate Chirp account profile.
gcphone:chirp:getTweetssource, data: tabletable[]Get tweets (paginated).
gcphone:chirp:publishTweetsource, data: tabletablePublish a tweet.
gcphone:chirp:toggleLikesource, data: tablebooleanToggle like on a tweet.
gcphone:chirp:toggleRechirpsource, data: tablebooleanToggle rechirp (retweet).
gcphone:chirp:getCommentssource, data: tabletable[]Get comments on a tweet.
gcphone:chirp:addCommentsource, data: tabletableAdd a comment/reply.
gcphone:chirp:deleteCommentsource, data: tablebooleanDelete a comment.
gcphone:chirp:deleteTweetsource, tweetId: integerbooleanDelete a tweet.
gcphone:chirp:followsource, data: tabletableFollow/unfollow a user.
gcphone:chirp:getProfilesource, data: tabletableGet a user profile.
gcphone:chirp:getPendingFollowRequestssourcetable[]Get pending follow requests.
gcphone:chirp:getSentFollowRequestssourcetable[]Get sent follow requests.
gcphone:chirp:respondFollowRequestsource, data: tablebooleanRespond to a follow request.
gcphone:chirp:cancelFollowRequestsource, data: tablebooleanCancel a sent follow request.

News

CallbackParametersReturnDescription
gcphone:news:getAccountsourcetableGet the News account.
gcphone:news:createAccountsource, data: tabletableCreate a News account.
gcphone:news:updateAccountsource, data: tabletableUpdate News account profile.
gcphone:news:getArticlessource, data: tabletable[]Get news articles (paginated).
gcphone:news:publishArticlesource, data: tabletablePublish an article.
gcphone:news:deleteArticlesource, articleId: integerbooleanDelete an article.
gcphone:news:viewArticlesource, articleId: integerbooleanRecord an article view.
gcphone:news:getCategoriessourcetable[]Get news categories.
gcphone:news:getLiveNewssourcetable[]Get active news live broadcasts.
gcphone:news:startLivesource, data: tabletableStart a news live broadcast.
gcphone:news:endLivesource, articleId: integerbooleanEnd a news live broadcast.
gcphone:news:joinLivesource, data: tabletableJoin a news live broadcast.
gcphone:news:leaveLivesource, data: tablebooleanLeave a news live broadcast.
gcphone:news:sendLiveMessagesource, data: tabletableSend a message in news live chat.
gcphone:news:sendLiveReactionsource, data: tablebooleanSend a reaction in news live.
gcphone:news:removeLiveMessagesource, data: tablebooleanRemove a news live message.
gcphone:news:muteLiveUsersource, data: tablebooleanMute a user in news live.
gcphone:news:setScaleformsource, data: tablebooleanSet the news scaleform overlay.
gcphone:news:getScaleformsource, articleId: integertableGet the scaleform for an article.

Notifications

CallbackParametersReturnDescription
gcphone:notifications:getsource, data: { limit?, offset? }tableGet notifications (paginated). Returns { success, notifications, unread }.
gcphone:notifications:markReadsource, data: { id: integer }booleanMark a notification as read.
gcphone:notifications:markAllReadsourcebooleanMark all notifications as read.
gcphone:notifications:deletesource, data: { id: integer }booleanDelete a notification.

Social Notifications

CallbackParametersReturnDescription
gcphone:social:getNotificationssource, data: tabletableGet social notifications.
gcphone:social:markNotificationReadsource, data: tablebooleanMark a social notification as read.
gcphone:social:markAllNotificationsReadsource, data: tablebooleanMark all social notifications as read.
gcphone:social:deleteNotificationsource, data: tablebooleanDelete a social notification.

Notes

CallbackParametersReturnDescription
gcphone:notes:getAllsourcetable[]Get all notes.
gcphone:notes:savesource, data: tabletableCreate or update a note.
gcphone:notes:deletesource, data: tablebooleanDelete a note.

Mail

CallbackParametersReturnDescription
gcphone:mail:getStatesource, data: tabletableGet mail state (accounts, unread count).
gcphone:mail:createAccountsource, data: tabletableCreate a mail account.
gcphone:mail:sendsource, data: tabletableSend an email.
gcphone:mail:markReadsource, data: tablebooleanMark a mail as read.
gcphone:mail:getMessagessource, data: tabletable[]Get mail messages (paginated).
gcphone:mail:deletesource, data: tablebooleanDelete a mail.

Security

CallbackParametersReturnDescription
gcphone:security:getBlockedNumberssourcetable[]Get blocked phone numbers.
gcphone:security:blockNumbersource, data: tablebooleanBlock a phone number.
gcphone:security:unblockNumbersource, data: tablebooleanUnblock a phone number.
gcphone:security:reportUsersource, data: tabletableReport a user.

Market

CallbackParametersReturnDescription
gcphone:market:getListingssource, data: tabletable[]Get market listings (paginated).
gcphone:market:getMyListingssourcetable[]Get the player's own listings.
gcphone:market:createListingsource, data: tabletableCreate a market listing.
gcphone:market:updateListingsource, data: tabletableUpdate a listing.
gcphone:market:deleteListingsource, listingId: integerbooleanDelete a listing.
gcphone:market:markAsSoldsource, listingId: integerbooleanMark a listing as sold.
gcphone:market:contactSellersource, data: tablebooleanContact a seller.
gcphone:market:getCategoriessourcetable[]Get market categories.

Yellow Pages

CallbackParametersReturnDescription
gcphone:yellowpages:getListingssource, data: tabletable[]Get yellow pages listings.
gcphone:yellowpages:getMyListingssource, data: tabletable[]Get the player's own listings.
gcphone:yellowpages:createListingsource, data: tabletableCreate a listing.
gcphone:yellowpages:deleteListingsource, listingId: integerbooleanDelete a listing.
gcphone:yellowpages:getSellerInfosource, listingId: integertableGet seller info for a listing.
gcphone:yellowpages:recordContactsource, data: tablebooleanRecord a contact interaction.
gcphone:yellowpages:shareLocationsource, listingId: integerbooleanShare seller location.
gcphone:yellowpages:getCategoriessourcetable[]Get yellow pages categories.

Proximity

CallbackParametersReturnDescription
gcphone:proximity:shareContactsource, data: tablebooleanShare a contact via proximity.
gcphone:proximity:acceptContactsource, data: tabletableAccept a proximity contact share.
gcphone:proximity:shareLocationsource, data: tablebooleanShare location with a nearby player.
gcphone:proximity:getSharedLocationssourcetable[]Get received shared locations.
gcphone:proximity:sendFriendRequestsource, data: tablebooleanSend a friend request.
gcphone:proximity:acceptFriendRequestsource, data: tablebooleanAccept a friend request.
gcphone:proximity:rejectFriendRequestsource, data: tablebooleanReject a friend request.
gcphone:proximity:sharePostsource, data: tablebooleanShare a social post via proximity.

Phone Drop

CallbackParametersReturnDescription
gcphone:dropPhonesourcetableDrop the phone in the world.
gcphone:getDroppedPhonessourcetable[]Get nearby dropped phones.
gcphone:pickupPhonesource, data: tabletablePick up a dropped phone.
gcphone:getPhoneInfosource, data: tabletableGet info about a dropped phone.
gcphone:unlockDroppedPhonesource, data: tabletableAttempt to unlock a dropped phone.

Darkrooms

CallbackParametersReturnDescription
gcphone:darkrooms:getRoomssourcetable[]Get available darkrooms.
gcphone:darkrooms:createRoomsource, data: tabletableCreate a new darkroom.
gcphone:darkrooms:joinRoomsource, data: tabletableJoin a darkroom.
gcphone:darkrooms:getPostssource, data: tabletable[]Get posts in a darkroom.
gcphone:darkrooms:createPostsource, data: tabletableCreate a post in a darkroom.
gcphone:darkrooms:votePostsource, data: tablebooleanVote on a darkroom post.
gcphone:darkrooms:getCommentssource, data: tabletable[]Get comments on a darkroom post.
gcphone:darkrooms:createCommentsource, data: tabletableAdd a comment to a darkroom post.

Documents

CallbackParametersReturnDescription
gcphone:documents:getListsourcetable[]Get all documents.
gcphone:documents:createsource, data: tabletableCreate a document.
gcphone:documents:deletesource, data: tablebooleanDelete a document.
gcphone:documents:toggleNFCsource, data: tablebooleanToggle NFC sharing for a document.
gcphone:documents:scanNFCsource, data: tabletableScan an NFC document.
gcphone:documents:verifysource, data: tabletableVerify a document.
gcphone:documents:getScanHistorysourcetable[]Get document scan history.
gcphone:documents:sharesource, data: tablebooleanShare a document via proximity.
gcphone:documents:getTypessourcetable[]Get available document types.

Storage & Media

CallbackParametersReturnDescription
gcphone:getStorageConfigsourcetableGet storage/upload configuration.
gcphone:storeMediaUrlsource, data: tabletableStore a media URL.
gcphone:storage:capturePhotosourcetableCapture and upload a photo.
gcphone:wavechat:getStatusMediaConfigsourcetableGet media config for WaveChat statuses.

Music

CallbackParametersReturnDescription
gcphone:music:searchCatalogsource, data: tabletable[]Search the music catalog.
gcphone:music:searchITunessource, data: tabletable[]Search iTunes for tracks.
gcphone:music:canSearchCatalog--booleanCheck if catalog search is available.

Location Tracking

CallbackParametersReturnDescription
gcphone:liveLocation:startsource, data: tabletableStart sharing live location.
gcphone:liveLocation:stopsourcebooleanStop sharing live location.
gcphone:liveLocation:getActivesourcetable[]Get active live location shares.

Garage

CallbackParametersReturnDescription
gcphone:garage:getVehiclessourcetable[]Get all vehicles for the player.
gcphone:garage:getVehiclesource, plate: stringtableGet a specific vehicle by plate.
gcphone:garage:updateLocationsource, data: tablebooleanUpdate vehicle location.
gcphone:garage:getLocationHistorysource, plate: stringtable[]Get location history for a vehicle.
gcphone:garage:requestVehiclesource, plate: stringbooleanRequest vehicle spawn at nearest garage.
gcphone:garage:getImpoundLocationsourceGaragePoint|nilGet the nearest impound location.
gcphone:garage:shareLocationsource, data: tablebooleanShare vehicle location with a contact.
gcphone:garage:storeVehiclesource, data: tablebooleanReturn a vehicle to the garage.
gcphone:garage:getStatssource, plate: stringtableGet vehicle statistics.

External / Misc

CallbackParametersReturnDescription
gcphone:wavechat:searchGifssource, data: tabletable[]Search for GIFs (Tenor/Giphy).
gcphone:socket:getTokensource, data: tabletableGet a WebSocket authentication token.
gcphone:livekit:getTokensource, data: tabletableGet a LiveKit room token for voice/video.

Released under GPL-3.0 License