Inherits from NSObject
Declared in QBRequest.h

Overview

QBRequest class interface. This class represents all requests to Quickblox API.

Tasks

Other Methods

  •   task

    The NSURLSessionTask class is the base class for tasks in a URL session.

    property
  •   canceled

    Determines if NSURLSessionTask was canceled.

    property
  • + new

    Unavailable Constructors

  • – init
  • – cancel

    Cancels NSURLSessionTask associated with request.

QBCustomObjects Methods

QBAuth Methods

QBPushNotifications Methods

QBLocation Methods

QBContent Methods

QBChat Methods

QBUsers Methods

Properties

canceled

@property (nonatomic, getter=isCancelled, readonly) BOOL canceled
Discussion

Determines if NSURLSessionTask was canceled.

Declared In

QBRequest.h

task

@property (nonatomic, readonly) NSURLSessionTask *task
Discussion

The NSURLSessionTask class is the base class for tasks in a URL session.

Declared In

QBRequest.h

Class Methods

TUpdateFileWithData:file:successBlock:statusBlock:errorBlock:

+ (QBRequest *)TUpdateFileWithData:(NSData *)data file:(QBCBlob *)file successBlock:(nullable qb_response_block_t)successBlock statusBlock:(nullable qb_response_status_block_t)statusBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Update File task. Contains 3 quieries: Update Blob, Upload file, Declaring file uploaded

Parameters

data

File to be uploaded

file

File which needs to be updated

successBlock

Block with response if request succeded

statusBlock

Block with upload/download progress

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

TUploadFile:fileName:contentType:isPublic:successBlock:statusBlock:errorBlock:

+ (QBRequest *)TUploadFile:(NSData *)data fileName:(NSString *)fileName contentType:(NSString *)contentType isPublic:(BOOL)isPublic successBlock:(nullable qb_response_blob_block_t)successBlock statusBlock:(nullable qb_response_status_block_t)statusBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Upload File task. Contains 3 requests: Create Blob, upload file, declaring file uploaded

Parameters

data

File to be uploaded

fileName

Name of the file

contentType

Type of the content in mime format

isPublic

Blob’s visibility

successBlock

Block with response if request succeded

statusBlock

Block with upload/download progress

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

backgroundDownloadFileFromClassName:objectID:fileFieldName:successBlock:statusBlock:errorBlock:

+ (QBRequest *)backgroundDownloadFileFromClassName:(NSString *)className objectID:(NSString *)objectID fileFieldName:(NSString *)fileFieldName successBlock:(nullable void ( ^ ) ( QBResponse *response , NSData *_Nullable loadedData ))successBlock statusBlock:(nullable qb_response_status_block_t)statusBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Download file using background NSURLSession.

If download is triggered by ‘content-available’ push - blocks will not be fired.

Parameters

className

Name of class

objectID

Identifier of object which file will be downloaded

fileFieldName

Name of file field

successBlock

Block with response instance and NSData instance if request succeded

statusBlock

Block with upload/download progress

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

backgroundDownloadFileWithID:successBlock:statusBlock:errorBlock:

+ (QBRequest *)backgroundDownloadFileWithID:(NSUInteger)fileID successBlock:(nullable void ( ^ ) ( QBResponse *response , NSData *fileData ))successBlock statusBlock:(nullable qb_response_status_block_t)statusBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Download File by file identifier using background NSURLSession.

If download is triggered by ‘content-available’ push - blocks will not be fired.

Parameters

fileID

File identifier.

successBlock

Block with response and fileData if request succeded

statusBlock

Block with upload/download progress

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

backgroundDownloadFileWithUID:successBlock:statusBlock:errorBlock:

+ (QBRequest *)backgroundDownloadFileWithUID:(NSString *)UID successBlock:(nullable void ( ^ ) ( QBResponse *response , NSData *fileData ))successBlock statusBlock:(nullable qb_response_status_block_t)statusBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Download file using background NSURLSession.

If download is triggered by ‘content-available’ push - blocks will not be fired.

Parameters

UID

File unique identifier, value of UID property of the QBCBlob instance.

successBlock

Block with response if request succeded

statusBlock

Block with upload/download progress

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

blobObjectAccessWithBlobID:successBlock:errorBlock:

+ (QBRequest *)blobObjectAccessWithBlobID:(NSUInteger)blobID successBlock:(nullable void ( ^ ) ( QBResponse *response , QBCBlobObjectAccess *objectAccess ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Get File by ID as BlobObjectAccess with read access

Parameters

blobID

Unique blob identifier, value of ID property of the QBCBlob instance.

successBlock

Block with response and blob instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

blobWithID:successBlock:errorBlock:

+ (QBRequest *)blobWithID:(NSUInteger)blobID successBlock:(nullable qb_response_blob_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve blob with ID.

Parameters

blobID

Unique blob identifier, value of ID property of the QBCBlob instance.

successBlock

Block with response and blob instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

blobsForPage:successBlock:errorBlock:

+ (QBRequest *)blobsForPage:(nullable QBGeneralResponsePage *)page successBlock:(nullable void ( ^ ) ( QBResponse *response , QBGeneralResponsePage *page , NSArray<QBCBlob*> *blobs ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Get list of blob for the current User (with extended set of pagination parameters)

Parameters

page

Page information

successBlock

Block with response, page and blob instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

blobsWithSuccessBlock:errorBlock:

+ (QBRequest *)blobsWithSuccessBlock:(nullable void ( ^ ) ( QBResponse *response , QBGeneralResponsePage *_Nullable page , NSArray<QBCBlob*> *_Nullable blobs ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Get list of blob for the current User (last 10 files)

Parameters

successBlock

Block with response, page and blob instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

completeBlobWithID:size:successBlock:errorBlock:

+ (QBRequest *)completeBlobWithID:(NSUInteger)blobID size:(NSUInteger)size successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Declaring Blob uploaded with ID

Parameters

blobID

Unique blob identifier, value of ID property of the QBCBlob instance.

size

Size of uploaded file, in bytes

successBlock

Block with response and blob instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

countObjectsWithClassName:extendedRequest:successBlock:errorBlock:

+ (QBRequest *)countObjectsWithClassName:(NSString *)className extendedRequest:(nullable NSMutableDictionary<NSString*,NSString*> *)extendedRequest successBlock:(nullable void ( ^ ) ( QBResponse *response , NSUInteger count ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Count of objects with extended Request

Parameters

className

Name of class

extendedRequest

Extended set of request parameters

successBlock

Block with response instance and count of objects if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

countOfDialogsWithExtendedRequest:successBlock:errorBlock:

+ (QBRequest *)countOfDialogsWithExtendedRequest:(nullable NSDictionary<NSString*,NSString*> *)parameters successBlock:(nullable qb_response_count_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Returns count of dialogs.

Parameters

parameters

Dialogs filter parameters.

successBlock

Block with response instance and count if request succeded.

errorBlock

Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

countOfMessagesForDialogID:extendedRequest:successBlock:errorBlock:

+ (QBRequest *)countOfMessagesForDialogID:(NSString *)dialogID extendedRequest:(nullable NSDictionary<NSString*,NSString*> *)parameters successBlock:(nullable qb_response_count_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Returns count of messages for dialog.

Parameters

dialogID

Dialog ID of the chat messages.

parameters

Messages filter parameters.

successBlock

Block with response instance and count if request succeded.

errorBlock

Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

createBlob:successBlock:errorBlock:

+ (QBRequest *)createBlob:(QBCBlob *)blob successBlock:(nullable qb_response_blob_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Create blob.

Parameters

blob

An instance of QBCBlob, describing the file to be uploaded.

successBlock

Block with response and blob instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

createDialog:successBlock:errorBlock:

+ (QBRequest *)createDialog:(QBChatDialog *)dialog successBlock:(nullable qb_response_dialog_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Create chat dialog

Parameters

dialog

chat dialog instance

successBlock

Block with response and created chat dialog instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

createEvent:successBlock:errorBlock:

+ (QBRequest *)createEvent:(QBMEvent *)event successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<QBMEvent*> *_Nullable events ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Create an event.

Parameters

event

An instance of QBMEvent to create

successBlock

Block with response and event instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

createGeoData:successBlock:errorBlock:

+ (QBRequest *)createGeoData:(QBLGeoData *)geoData successBlock:(nullable void ( ^ ) ( QBResponse *response , QBLGeoData *_Nullable geoData ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Create geo data

Parameters

geoData

An instance of QBLGeoData

successBlock

Block with response and geodata instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBLocation.h

createMessage:successBlock:errorBlock:

+ (QBRequest *)createMessage:(QBChatMessage *)message successBlock:(nullable qb_response_message_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Create chat message.

Parameters

message

Сhat message instance to create.

successBlock

Block with response and chat message instance if request succeded.

errorBlock

Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

createObject:successBlock:errorBlock:

+ (QBRequest *)createObject:(QBCOCustomObject *)object successBlock:(nullable void ( ^ ) ( QBResponse *response , QBCOCustomObject *_Nullable object ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Create record

Parameters

object

An instance of object that will be created

successBlock

Block with response instance and created object if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

createObjects:className:successBlock:errorBlock:

+ (QBRequest *)createObjects:(NSArray<QBCOCustomObject*> *)objects className:(NSString *)className successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<QBCOCustomObject*> *_Nullable objects ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Create records

Parameters

objects

An array of instances of objects that will be created

className

Name of class

successBlock

Block with response instance, NSArray of created objects if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

createSubscription:successBlock:errorBlock:

+ (QBRequest *)createSubscription:(QBMSubscription *)subscription successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<QBMSubscription*> *_Nullable objects ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Create subscription.

Parameters

subscription

An instance of QBMSubscription

successBlock

Block with response and subscriber instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

deleteBlobWithID:successBlock:errorBlock:

+ (QBRequest *)deleteBlobWithID:(NSUInteger)blobID successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Delete Blob

Parameters

blobID

Unique blob identifier, value of ID property of the QBCBlob instance.

successBlock

Block with response if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

deleteCurrentUserWithSuccessBlock:errorBlock:

+ (QBRequest *)deleteCurrentUserWithSuccessBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Delete Current User

Note: You should login firstly in order to delete current user

Parameters

successBlock

Block with response instance if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

deleteDialogsWithIDs:forAllUsers:successBlock:errorBlock:

+ (QBRequest *)deleteDialogsWithIDs:(NSSet<NSString*> *)dialogIDs forAllUsers:(BOOL)forAllUsers successBlock:(nullable qb_response_delete_dialog_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Delete dialogs

Passing YES to ‘forAllUsers’ requires current user to be owner of the dialog! If current user is not the owner - request fails.

Parameters

dialogIDs

The IDs of a dialogs to delete.

forAllUsers

Delete dialog for current user or remove it for all users.

successBlock

Block with response if request succeded.

errorBlock

Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

deleteEventWithID:successBlock:errorBlock:

+ (QBRequest *)deleteEventWithID:(NSUInteger)ID successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Get an event with ID.

Parameters

ID

ID of QBMEvent to be deleted.

successBlock

Block with response instance if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

deleteFileFromClassName:objectID:fileFieldName:successBlock:errorBlock:

+ (QBRequest *)deleteFileFromClassName:(NSString *)className objectID:(NSString *)objectID fileFieldName:(NSString *)fileFieldName successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Delete file

Parameters

className

Name of class

objectID

Identifier of object form which file will be deleted

fileFieldName

Name of file field

successBlock

Block with response instance if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

deleteGeoDataWithID:successBlock:errorBlock:

+ (QBRequest *)deleteGeoDataWithID:(NSUInteger)geodataID successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Delete geo data by ID

Parameters

geodataID

ID of instance of QBLGeoData that will be deleted

successBlock

Block with response instance if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBLocation.h

deleteGeoDataWithRemainingDays:successBlock:errorBlock:

+ (QBRequest *)deleteGeoDataWithRemainingDays:(NSUInteger)days successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Delete geo data with remaining days

Parameters

days

Maximum age of data that must remain in the database after a query.

successBlock

Block with response instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBLocation.h

deleteMessagesWithIDs:forAllUsers:successBlock:errorBlock:

+ (QBRequest *)deleteMessagesWithIDs:(NSSet<NSString*> *)messageIDs forAllUsers:(BOOL)forAllUsers successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Delete existent chat messages completely for all users

Passing YES to ‘forAllUsers’ requires current user to be the owner of the message! If the current user is not the owner - request fails.

Parameters

messageIDs

The IDs of messages to delete.

forAllUsers

Delete message for the current user or remove it for all users.

successBlock

Block with response instance if the request succeeded.

errorBlock

Block with response instance if the request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

deleteObjectWithID:className:successBlock:errorBlock:

+ (QBRequest *)deleteObjectWithID:(NSString *)objectID className:(NSString *)className successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Delete object by identifier

Parameters

objectID

ID of object to be removed.

successBlock

Block with response instance if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

deleteObjectsWithIDs:className:successBlock:errorBlock:

+ (QBRequest *)deleteObjectsWithIDs:(NSArray<NSString*> *)objectsIDs className:(NSString *)className successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<NSString*> *_Nullable deletedObjectsIDs , NSArray<NSString*> *_Nullable notFoundObjectsIDs , NSArray<NSString*> *_Nullable wrongPermissionsObjectsIDs ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Delete objects by IDs

Parameters

objectsIDs

Array of IDs of objects to be removed.

successBlock

Block with response instance, NSArray of deleted objects Ids and NSArray of not found objects Ids if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

deleteSubscriptionWithID:successBlock:errorBlock:

+ (QBRequest *)deleteSubscriptionWithID:(NSUInteger)ID successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Delete subscription with ID.

Parameters

ID

An ID of instance of QBMSubscription that will be deleted

successBlock

Block with response instance if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

destroySessionWithSuccessBlock:errorBlock:

+ (QBRequest *)destroySessionWithSuccessBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Session Destroy

Parameters

successBlock

Block with response instance if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBAuth.h

dialogsForPage:extendedRequest:successBlock:errorBlock:

+ (QBRequest *)dialogsForPage:(QBResponsePage *)page extendedRequest:(nullable NSDictionary<NSString*,NSString*> *)extendedRequest successBlock:(nullable qb_response_dialogs_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve chat dialogs for page

Parameters

page

Page with skip and limit

extendedRequest

Set of request parameters

successBlock

Block with response instance, arrays of chat dialogs and chat dialogs users IDs and page instance if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

dialogsWithSuccessBlock:errorBlock:

+ (QBRequest *)dialogsWithSuccessBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<QBChatDialog*> *dialogObjects , NSSet<NSNumber*> *dialogsUsersIDs ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve chat dialogs

Parameters

successBlock

Block with response instance and arrays of chat dialogs and chat dialogs users IDs if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

downloadFileFromClassName:objectID:fileFieldName:successBlock:statusBlock:errorBlock:

+ (QBRequest *)downloadFileFromClassName:(NSString *)className objectID:(NSString *)objectID fileFieldName:(NSString *)fileFieldName successBlock:(nullable void ( ^ ) ( QBResponse *response , NSData *_Nullable loadedData ))successBlock statusBlock:(nullable qb_response_status_block_t)statusBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Download file

Parameters

className

Name of class

objectID

Identifier of object which file will be downloaded

fileFieldName

Name of file field

successBlock

Block with response instance and NSData instance if request succeded

statusBlock

Block with upload/download progress

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

downloadFileWithID:successBlock:statusBlock:errorBlock:

+ (QBRequest *)downloadFileWithID:(NSUInteger)fileID successBlock:(nullable void ( ^ ) ( QBResponse *response , NSData *fileData ))successBlock statusBlock:(nullable qb_response_status_block_t)statusBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Download File by file identifier.

Parameters

fileID

File identifier.

successBlock

Block with response and fileData if request succeded

statusBlock

Block with upload/download progress

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

downloadFileWithUID:successBlock:statusBlock:errorBlock:

+ (QBRequest *)downloadFileWithUID:(NSString *)UID successBlock:(nullable void ( ^ ) ( QBResponse *response , NSData *fileData ))successBlock statusBlock:(nullable qb_response_status_block_t)statusBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Download file

Parameters

UID

File unique identifier, value of UID property of the QBCBlob instance.

successBlock

Block with response if request succeded

statusBlock

Block with upload/download progress

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

eventWithID:successBlock:errorBlock:

+ (QBRequest *)eventWithID:(NSUInteger)ID successBlock:(nullable void ( ^ ) ( QBResponse *response , QBMEvent *_Nullable event ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Get an event with ID.

Parameters

ID

ID of QBMEvent to be retrieved

successBlock

Block with response and event instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

eventsForPage:successBlock:errorBlock:

+ (QBRequest *)eventsForPage:(nullable QBGeneralResponsePage *)page successBlock:(nullable void ( ^ ) ( QBResponse *response , QBGeneralResponsePage *_Nullable page , NSArray<QBMEvent*> *_Nullable events ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve all events which were created by current user (with extended set of pagination parameters).

Parameters

page

Configured QBLGeneralResponsePage instance

successBlock

Block with response, page, events instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

geoDataWithFilter:page:successBlock:errorBlock:

+ (QBRequest *)geoDataWithFilter:(QBLGeoDataFilter *)filter page:(nullable QBGeneralResponsePage *)page successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<QBLGeoData*> *_Nullable objects , QBGeneralResponsePage *_Nullable page ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Get multiple geo data

Parameters

filter

QBLGeoDataFilter with filter values set

page

Requested page

successBlock

Block with response instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBLocation.h

geoDataWithId:successBlock:errorBlock:

+ (QBRequest *)geoDataWithId:(NSUInteger)geoDataId successBlock:(nullable void ( ^ ) ( QBResponse *response , QBLGeoData *_Nullable geoData ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Get geo data by ID

Parameters

geoDataId

ID of instance of QBLGeoData that will be retrieved

successBlock

Block with response and geodata instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBLocation.h

logInWithFirebaseProjectID:accessToken:successBlock:errorBlock:

+ (QBRequest *)logInWithFirebaseProjectID:(NSString *)projectID accessToken:(NSString *)accessToken successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

User login using Firebase (only phone number. See https://firebase.google.com/docs/auth/ios/phone-auth)..)

Parameters

projectID

Firebase project ID

accessToken

Access token

successBlock

Block with response and user instances if request succeded.

errorBlock

Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBAuth.h

logInWithSocialProvider:accessToken:accessTokenSecret:successBlock:errorBlock:

+ (QBRequest *)logInWithSocialProvider:(NSString *)provider accessToken:(nullable NSString *)accessToken accessTokenSecret:(nullable NSString *)accessTokenSecret successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

User LogIn with social provider’s token

Parameters

provider

Social provider. Posible values: facebook, twitter.

accessToken

Social provider access token.

accessTokenSecret

Social provider access token secret.

successBlock

Block with response and user instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBAuth.h

logInWithTwitterDigitsAuthHeaders:successBlock:errorBlock:

+ (QBRequest *)logInWithTwitterDigitsAuthHeaders:(NSDictionary *)headers successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

User login using Twitter Digits.

Warning: Deprecated in 2.10 Use ‘logInWithFirebaseProjectID:accessToken:successBlock:errorBlock:’.

Parameters

headers

Taken from ‘[DGTOAuthSigning OAuthEchoHeadersToVerifyCredentials]’.

successBlock

Block with response and user instances if request succeded.

errorBlock

Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBAuth.h

logInWithUserEmail:password:successBlock:errorBlock:

+ (QBRequest *)logInWithUserEmail:(NSString *)email password:(NSString *)password successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

User LogIn with email

Parameters

email

Email of QBUUser which authenticates.

password

Password of QBUUser which authenticates.

successBlock

Block with response and user instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBAuth.h

logInWithUserLogin:password:successBlock:errorBlock:

+ (QBRequest *)logInWithUserLogin:(NSString *)login password:(NSString *)password successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

User LogIn with login

Parameters

login

Login of QBUUser which authenticates.

password

Password of QBUUser which authenticates.

successBlock

Block with response and user instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBAuth.h

logOutWithSuccessBlock:errorBlock:

+ (QBRequest *)logOutWithSuccessBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

LogOut current user

Parameters

successBlock

Block with response instance if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBAuth.h

markMessagesAsDelivered:dialogID:successBlock:errorBlock:

+ (QBRequest *)markMessagesAsDelivered:(nullable NSSet<NSString*> *)messagesIDs dialogID:(NSString *)dialogID successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Mark messages as Delivered.

Note: Updates message “delivered” status only on server.

Parameters

messagesIDs

Set of chat message IDs to mark as delivered. If messageIDs is nil then all messages in dialog will be marked as delivered.

dialogID

dialog ID.

successBlock

Block with response instance if request succeded.

errorBlock

Block with response instance if request failed.

Return Value

An instance, which conforms Cancelable protocol. Use this instance to cancel the operation.

Declared In

QBRequest+QBChat.h

markMessagesAsRead:dialogID:successBlock:errorBlock:

+ (QBRequest *)markMessagesAsRead:(nullable NSSet<NSString*> *)messagesIDs dialogID:(NSString *)dialogID successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Mark messages as read.

Note: Updates message “read” status only on server.

Parameters

messagesIDs

Set of chat message IDs to mark as read. If messageIDs is nil then all messages in dialog will be marked as read.

dialogID

dialog ID.

successBlock

Block with response instance if request succeded.

errorBlock

Block with response instance if request failed.

Return Value

An instance, which conforms Cancelable protocol. Use this instance to cancel the operation.

Declared In

QBRequest+QBChat.h

messagesWithDialogID:extendedRequest:forPage:successBlock:errorBlock:

+ (QBRequest *)messagesWithDialogID:(NSString *)dialogID extendedRequest:(nullable NSDictionary<NSString*,NSString*> *)extendedParameters forPage:(nullable QBResponsePage *)page successBlock:(nullable qb_response_messages_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve chat messages within particular dialog for page.

By default all messages retrieved from server is marked as read, if you need another behaviour please use mark_as_read parameter in extendedParameters dictionary.

@code [extendedParameters setObject:@“0” forKey:@“mark_as_read”]; @endcode

Parameters

dialogID

ID of a dialog.

extendedParameters

A set of additional request parameters.

page

response page instance.

successBlock

Block with response instance and array of chat messages for page if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

messagesWithDialogID:successBlock:errorBlock:

+ (QBRequest *)messagesWithDialogID:(NSString *)dialogID successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<QBChatMessage*> *messages ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve first 100 chat messages within particular dialog

Parameters

dialogID

ID of a dialog

successBlock

Block with response instance and array of chat messages if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

new

+ (instancetype)new
Discussion

Unavailable Constructors

Declared In

QBRequest.h

notificationsSettingsForDialogID:successBlock:errorBlock:

+ (QBRequest *)notificationsSettingsForDialogID:(NSString *)dialogID successBlock:(nullable void ( ^ ) ( BOOL enabled ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Get the notifications settings status.

Parameters

dialogID

Dialog ID

successBlock

Block with current status of notifications settings.

errorBlock

errorBlock Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

objectWithClassName:ID:successBlock:errorBlock:

+ (QBRequest *)objectWithClassName:(NSString *)className ID:(NSString *)ID successBlock:(nullable void ( ^ ) ( QBResponse *response , QBCOCustomObject *_Nullable object ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve object with ID

Parameters

className

Name of class

ID

Identifier of object to be retrieved

successBlock

Block with response instance and QBCOCustomObject instance if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

objectsWithClassName:IDs:successBlock:errorBlock:

+ (QBRequest *)objectsWithClassName:(NSString *)className IDs:(NSArray<NSString*> *)IDs successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray *_Nullable objects ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve objects with IDs

Parameters

className

Name of class

IDs

Identifiers of objects to be retrieved

successBlock

Block with response instance, NSArray of found objects if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

objectsWithClassName:aggregationOperator:forFieldName:groupByFieldName:extendedRequest:successBlock:errorBlock:

+ (QBRequest *)objectsWithClassName:(NSString *)className aggregationOperator:(QBCOAggregationOperator)aggregationOperator forFieldName:(NSString *)fieldName groupByFieldName:(NSString *)groupFieldName extendedRequest:(nullable NSMutableDictionary<NSString*,NSString*> *)extendedRequest successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<QBCOCustomObject*> *_Nullable objects , QBResponsePage *_Nullable responsePage ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Returns calculated data for specified objects

Parameters

className

Required. Name of class.

aggregationOperator

Required. Maximum, minimum, average or summary.

fieldName

Required. Field name which will be used for calculation.

groupFieldName

Required. Field name for group.

extendedRequest

Optional. Extended set of request parameters. count parameter is ignored. To receive count use countObjectsWithClassName:extendedRequest:successBlock:errorBlock:.

successBlock

Block with response instance, NSArray of grouped objects.

errorBlock

Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

objectsWithClassName:extendedRequest:successBlock:errorBlock:

+ (QBRequest *)objectsWithClassName:(NSString *)className extendedRequest:(nullable NSMutableDictionary<NSString*,NSString*> *)extendedRequest successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<QBCOCustomObject*> *_Nullable objects , QBResponsePage *_Nullable page ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve objects with extended Request

Parameters

className

Name of class

extendedRequest

Extended set of request parameters. count parameter is ignored. To receive count use countObjectsWithClassName:extendedRequest:successBlock:errorBlock:

successBlock

Block with response instance, NSArray of found objects, NSArray of not found objects Ids and QBResponsePage if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

objectsWithClassName:successBlock:errorBlock:

+ (QBRequest *)objectsWithClassName:(NSString *)className successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray *_Nullable objects ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve objects

Parameters

className

Name of class

successBlock

Block with response instance, NSArray of found objects, NSArray of not found objects Ids and QBResponsePage if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

permissionsForObjectWithClassName:ID:successBlock:errorBlock:

+ (QBRequest *)permissionsForObjectWithClassName:(NSString *)className ID:(NSString *)ID successBlock:(nullable void ( ^ ) ( QBResponse *response , QBCOPermissions *permissions ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve permissions for object with ID

Parameters

className

Name of class

ID

Identifier of object which permissions will be retrieved

successBlock

Block with response instance and QBCOPermissions instance if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

resetUserPasswordWithEmail:successBlock:errorBlock:

+ (QBRequest *)resetUserPasswordWithEmail:(NSString *)email successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Reset user’s password. User with this email will retrieve an email instruction for reset password.

Parameters

email

User’s email

successBlock

Block with response instance if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

sendMessage:successBlock:errorBlock:

+ (QBRequest *)sendMessage:(QBChatMessage *)message successBlock:(nullable qb_response_message_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Create and send message to chat.

Parameters

message

Сhat message instance to create.

successBlock

Block with response and chat message instance if request succeded.

errorBlock

Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

sendPush:toUsers:successBlock:errorBlock:

+ (QBRequest *)sendPush:(QBMPushMessage *)pushMessage toUsers:(NSString *)usersIDs successBlock:(nullable void ( ^ ) ( QBResponse *response , QBMEvent *_Nullable event ))successBlock errorBlock:(nullable QBErrorBlock)errorBlock
Discussion

Send Apple based push notification to users.

Parameters

pushMessage

Composed push message to send

usersIDs

Users identifiers who will get the message. Contain a string of users ids divided by comas

successBlock

Block with response and event instances if request succeded

errorBlock

Block with error if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

sendPush:toUsersWithAnyOfTheseTags:successBlock:errorBlock:

+ (QBRequest *)sendPush:(QBMPushMessage *)pushMessage toUsersWithAnyOfTheseTags:(NSString *)usersTags successBlock:(nullable void ( ^ ) ( QBResponse *response , QBMEvent *_Nullable event ))successBlock errorBlock:(nullable QBErrorBlock)errorBlock
Discussion

Send Apple based push notification to users with tags.

Parameters

pushMessage

composed push message to send

usersTags

users tags who will get the message. Contain a string of users tags divided by comas

successBlock

Block with response and event instances if request succeded

errorBlock

Block with error if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

sendPushWithText:toUsers:successBlock:errorBlock:

+ (QBRequest *)sendPushWithText:(NSString *)text toUsers:(NSString *)usersIDs successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<QBMEvent*> *_Nullable events ))successBlock errorBlock:(nullable QBErrorBlock)errorBlock
Discussion

Send simple push notification to users.

Parameters

text

composed push notification’s text to send

usersIDs

users identifiers who will get the message. Contain a string of users ids divided by comas.

successBlock

Block with response and event instances if request succeded

errorBlock

Block with error if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

sendPushWithText:toUsersWithAnyOfTheseTags:successBlock:errorBlock:

+ (QBRequest *)sendPushWithText:(NSString *)text toUsersWithAnyOfTheseTags:(NSString *)usersTags successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<QBMEvent*> *_Nullable events ))successBlock errorBlock:(nullable QBErrorBlock)errorBlock
Discussion

Send simple push notification to users with tags.

Parameters

text

composed push notification’s text to send

usersTags

users tags who will get the message. Contain a string of users tags divided by comas.

successBlock

Block with response and token instances if request succeded

errorBlock

Block with response instance and QBMEvent instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

sendVoipPush:toUsers:successBlock:errorBlock:

+ (QBRequest *)sendVoipPush:(QBMPushMessage *)pushMessage toUsers:(NSString *)usersIDs successBlock:(nullable void ( ^ ) ( QBResponse *response , QBMEvent *_Nullable event ))successBlock errorBlock:(nullable QBErrorBlock)errorBlock
Discussion

Send apns-voip push notification to users.

Parameters

pushMessage

Composed push message to send

usersIDs

Users identifiers who will get the message. Contain a string of users ids divided by comas

successBlock

Block with response and event instances if request succeded

errorBlock

Block with error if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

sendVoipPush:toUsersWithAnyOfTheseTags:successBlock:errorBlock:

+ (QBRequest *)sendVoipPush:(QBMPushMessage *)pushMessage toUsersWithAnyOfTheseTags:(NSString *)usersTags successBlock:(nullable void ( ^ ) ( QBResponse *response , QBMEvent *_Nullable event ))successBlock errorBlock:(nullable QBErrorBlock)errorBlock
Discussion

Send apns-voip push notification to users with tags.

Parameters

pushMessage

composed push message to send

usersTags

users tags who will get the message. Contain a string of users tags divided by comas

successBlock

Block with response and event instances if request succeded

errorBlock

Block with error if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

signUp:successBlock:errorBlock:

+ (QBRequest *)signUp:(QBUUser *)user successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

User sign up

Parameters

user

User to signup

successBlock

Block with response and user instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest. Use this instance to cancel the operation.

Declared In

QBRequest+QBAuth.h

subscriptionsWithSuccessBlock:errorBlock:

+ (QBRequest *)subscriptionsWithSuccessBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<QBMSubscription*> *_Nullable objects ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve all subscriptions.

Parameters

successBlock

Block with response and subscribers instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

taggedBlobsForPage:successBlock:errorBlock:

+ (QBRequest *)taggedBlobsForPage:(nullable QBGeneralResponsePage *)page successBlock:(nullable void ( ^ ) ( QBResponse *response , QBGeneralResponsePage *page , NSArray<QBCBlob*> *blobs ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Get list of tagged blobs for the current User (with extended set of pagination parameters)

Parameters

page

Page information

successBlock

Block with response, page and blob instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

taggedBlobsWithSuccessBlock:errorBlock:

+ (QBRequest *)taggedBlobsWithSuccessBlock:(nullable void ( ^ ) ( QBResponse *response , QBGeneralResponsePage *page , NSArray<QBCBlob*> *_Nullable blobs ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Get list of tagged blobs for the current User (last 10 files)

Parameters

successBlock

Block with response, page and blob instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

totalUnreadMessageCountForDialogsWithIDs:successBlock:errorBlock:

+ (QBRequest *)totalUnreadMessageCountForDialogsWithIDs:(NSSet<NSString*> *)dialogIDs successBlock:(nullable qb_response_unread_messages_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Returns unread message count for dialogs with ids. Includes total count for all dialogs for user also.

Parameters

dialogIDs

Array of dialog IDs.

successBlock

Block with response instance total unread count and dialogs dictionary.

errorBlock

Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

unregisterSubscriptionForUniqueDeviceIdentifier:successBlock:errorBlock:

+ (QBRequest *)unregisterSubscriptionForUniqueDeviceIdentifier:(NSString *)uniqueDeviceIdentifier successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable QBErrorBlock)errorBlock
Discussion

Remove subscription for a specific device. This method remove subscription for a specific device.

Parameters

uniqueDeviceIdentifier

The device unique identifier

successBlock

Block with response instance if request succeded

errorBlock

Block with error if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

updateBlob:successBlock:errorBlock:

+ (QBRequest *)updateBlob:(QBCBlob *)blob successBlock:(nullable qb_response_blob_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Update Blob

Parameters

blob

An instance of QBCBlob to be updated.

successBlock

Block with response and blob instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

updateCurrentUser:successBlock:errorBlock:

+ (QBRequest *)updateCurrentUser:(QBUpdateUserParameters *)parameters successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Update current session user.

Parameters

parameters

User parameters that could be updated.

successBlock

Block with response and user instances if request succeded.

errorBlock

Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

updateDialog:successBlock:errorBlock:

+ (QBRequest *)updateDialog:(QBChatDialog *)dialog successBlock:(nullable qb_response_dialog_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Update existing chat dialog

Parameters

dialog

The dialog instance to update

successBlock

Block with response and updated chat dialog instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

updateEvent:successBlock:errorBlock:

+ (QBRequest *)updateEvent:(QBMEvent *)event successBlock:(nullable void ( ^ ) ( QBResponse *response , QBMEvent *_Nullable event ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Update an event.

Parameters

event

An instance of QBMEvent to update

successBlock

Block with response and event instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBPushNotifications.h

updateGeoData:successBlock:errorBlock:

+ (QBRequest *)updateGeoData:(QBLGeoData *)geodata successBlock:(nullable void ( ^ ) ( QBResponse *response , QBLGeoData *_Nullable geoData ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Update geo data

Parameters

geodata

An instance of QBLGeoData

successBlock

Block with response and geodata instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBLocation.h

updateMessage:successBlock:errorBlock:

+ (QBRequest *)updateMessage:(QBChatMessage *)message successBlock:(nullable qb_response_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Update existing chat message - mark it as read.

Note: Updates message “read” status only on server.

Warning: Deprecated in 2.10 Use ‘markMessagesAsRead:dialogID:successBlock:errorBlock:’.

Parameters

message

Сhat message to update.

successBlock

Block with response instance if request succeded.

errorBlock

Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

updateNotificationsSettingsForDialogID:enable:successBlock:errorBlock:

+ (QBRequest *)updateNotificationsSettingsForDialogID:(NSString *)dialogID enable:(BOOL)enable successBlock:(nullable void ( ^ ) ( BOOL enabled ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

User can turn YES/NO push notifications for offline messages in a dialog. Default value is YES. By default when a user is offline and other user sent a message to him then he will receive a push notification. It is possible to disable this feature.

Parameters

dialogID

Dialog ID

enable

YES / NO

successBlock

Block with current status of notifications settings.

errorBlock

errorBlock Block with response instance if request failed.

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBChat.h

updateObject:specialUpdateOperators:successBlock:errorBlock:

+ (QBRequest *)updateObject:(QBCOCustomObject *)object specialUpdateOperators:(NSMutableDictionary<NSString*,NSString*> *)specialUpdateOperators successBlock:(nullable void ( ^ ) ( QBResponse *response , QBCOCustomObject *_Nullable object ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Update record with Special update operators

Parameters

object

An instance of object that will be updated

specialUpdateOperators

Special update operators http://quickblox.com/developers/SimpleSample-customObjects-ios#Special_update_oparators

successBlock

Block with response instance and updated object if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

updateObject:successBlock:errorBlock:

+ (QBRequest *)updateObject:(QBCOCustomObject *)object successBlock:(nullable void ( ^ ) ( QBResponse *response , QBCOCustomObject *_Nullable object ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Update record

Parameters

object

An instance of object that will be updated

successBlock

Block with response instance and updated object if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

updateObjects:className:successBlock:errorBlock:

+ (QBRequest *)updateObjects:(NSArray<QBCOCustomObject*> *)objects className:(NSString *)className successBlock:(nullable void ( ^ ) ( QBResponse *response , NSArray<QBCOCustomObject*> *_Nullable objects , NSArray<NSString*> *_Nullable notFoundObjectsIds ))successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Update records

Parameters

objects

An array of instances of objects that will be updated

className

Name of class

successBlock

Block with response instance, updated objects and not found objects Ids if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

uploadFile:blobWithWriteAccess:successBlock:statusBlock:errorBlock:

+ (QBRequest *)uploadFile:(nullable NSData *)data blobWithWriteAccess:(QBCBlob *)blobWithWriteAccess successBlock:(nullable qb_response_block_t)successBlock statusBlock:(nullable qb_response_status_block_t)statusBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Upload file using BlobObjectAccess

Parameters

data

File

blobWithWriteAccess

An instance of QBCBlobObjectAccess

successBlock

Block with response if request succeded

statusBlock

Block with upload/download progress

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

uploadFile:className:objectID:fileFieldName:successBlock:statusBlock:errorBlock:

+ (QBRequest *)uploadFile:(QBCOFile *)file className:(NSString *)className objectID:(NSString *)objectID fileFieldName:(NSString *)fileFieldName successBlock:(nullable void ( ^ ) ( QBResponse *response , QBCOFileUploadInfo *_Nullable info ))successBlock statusBlock:(nullable qb_response_status_block_t)statusBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Upload file

Parameters

file

File

className

Name of class

objectID

Identifier of object to which file will be uploaded

fileFieldName

Name of file field

successBlock

Block with response instance if request succeded

statusBlock

Block with upload/download progress

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBCustomObjects.h

uploadFileWithUrl:fileName:contentType:isPublic:successBlock:statusBlock:errorBlock:

+ (QBRequest *)uploadFileWithUrl:(NSURL *)url fileName:(NSString *)fileName contentType:(NSString *)contentType isPublic:(BOOL)isPublic successBlock:(nullable qb_response_blob_block_t)successBlock statusBlock:(nullable qb_response_status_block_t)statusBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Upload File task. Contains 3 requests: Create Blob, upload file, declaring file uploaded

Parameters

url

File url to be uploaded

fileName

Name of the file

contentType

Type of the content in mime format

isPublic

Blob’s visibility

successBlock

Block with response if request succeded

statusBlock

Block with upload/download progress

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBContent.h

userWithEmail:successBlock:errorBlock:

+ (QBRequest *)userWithEmail:(NSString *)userEmail successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve User by Email

Parameters

userEmail

Email of user to be retrieved.

successBlock

Block with response and user instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

userWithExternalID:successBlock:errorBlock:

+ (QBRequest *)userWithExternalID:(NSUInteger)userExternalID successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve User by External identifier

Parameters

userExternalID

External ID of user to be retrieved.

successBlock

Block with response and user instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

userWithFacebookID:successBlock:errorBlock:

+ (QBRequest *)userWithFacebookID:(NSString *)userFacebookID successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve User by Facebook ID

Parameters

userFacebookID

Facebook ID of user to be retrieved.

successBlock

Block with response and user instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

userWithID:successBlock:errorBlock:

+ (QBRequest *)userWithID:(NSUInteger)userID successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve User by identifier

Parameters

userID

ID of QBUUser to be retrieved.

successBlock

Block with response and user instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

userWithLogin:successBlock:errorBlock:

+ (QBRequest *)userWithLogin:(NSString *)userLogin successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve User by login

Parameters

userLogin

Login of user to be retrieved.

successBlock

Block with response and user instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

userWithTwitterID:successBlock:errorBlock:

+ (QBRequest *)userWithTwitterID:(NSString *)userTwitterID successBlock:(nullable qb_response_user_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve User by Twitter ID

Parameters

userTwitterID

Twitter ID of user to be retrieved.

successBlock

Block with response and user instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

usersForPage:successBlock:errorBlock:

+ (QBRequest *)usersForPage:(nullable QBGeneralResponsePage *)page successBlock:(nullable qb_response_users_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve all Users for current account (with extended set of pagination parameters)

Parameters

page

Pagination parameters

successBlock

Block with response, page and users instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

usersWithEmails:page:successBlock:errorBlock:

+ (QBRequest *)usersWithEmails:(NSArray<NSString*> *)emails page:(nullable QBGeneralResponsePage *)page successBlock:(nullable qb_response_users_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve users with email (with extended set of pagination parameters)

Parameters

emails

Emails of users which you want to retrieve

page

Pagination parameters

successBlock

Block with response, page and users instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

usersWithExtendedRequest:page:successBlock:errorBlock:

+ (QBRequest *)usersWithExtendedRequest:(NSDictionary<NSString*,id> *)extendedRequest page:(nullable QBGeneralResponsePage *)responsePage successBlock:(nullable qb_response_users_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve all Users for current account with extended request

Parameters

extendedRequest

Dictionary with extended request

responsePage

Pagination parameters

successBlock

Block with response, page and users instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

usersWithFacebookIDs:page:successBlock:errorBlock:

+ (QBRequest *)usersWithFacebookIDs:(NSArray<NSString*> *)facebookIDs page:(nullable QBGeneralResponsePage *)page successBlock:(nullable qb_response_users_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve users with facebook ids (with extended set of pagination parameters)

Parameters

facebookIDs

Facebook IDs of users which you want to retrieve

page

Pagination parameters

successBlock

Block with response, page and users instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

usersWithFullName:page:successBlock:errorBlock:

+ (QBRequest *)usersWithFullName:(NSString *)userFullName page:(nullable QBGeneralResponsePage *)page successBlock:(nullable qb_response_users_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve Users by full name for current account (with extended set of pagination parameters)

Parameters

userFullName

Full name of users to be retrieved.

page

Pagination parameters

successBlock

Block with response, page and users instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

usersWithIDs:page:successBlock:errorBlock:

+ (QBRequest *)usersWithIDs:(NSArray<NSString*> *)IDs page:(nullable QBGeneralResponsePage *)page successBlock:(nullable qb_response_users_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve users with ids (with extended set of pagination parameters)

Parameters

IDs

IDs of users which you want to retrieve

page

Pagination parameters

successBlock

Block with response, page and users instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

usersWithLogins:page:successBlock:errorBlock:

+ (QBRequest *)usersWithLogins:(NSArray<NSString*> *)logins page:(nullable QBGeneralResponsePage *)page successBlock:(nullable qb_response_users_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve users with logins (with extended set of pagination parameters)

Parameters

logins

Logins of users which you want to retrieve

page

Pagination parameters

successBlock

Block with response, page and users instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

usersWithPhoneNumbers:page:successBlock:errorBlock:

+ (QBRequest *)usersWithPhoneNumbers:(NSArray<NSString*> *)phoneNumbers page:(nullable QBGeneralResponsePage *)page successBlock:(nullable qb_response_users_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve users with phone numbers (with extended set of pagination parameters)

Parameters

phoneNumbers

Pnone numbers of users which you want to retrieve

page

Pagination parameters

successBlock

Block with response, page and users instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

usersWithTags:page:successBlock:errorBlock:

+ (QBRequest *)usersWithTags:(NSArray<NSString*> *)tags page:(nullable QBGeneralResponsePage *)page successBlock:(nullable qb_response_users_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve Users by tags for current account (with extended set of pagination parameters)

Parameters

tags

Tags of users to be retrieved.

page

Pagination parameters

successBlock

Block with response, page and users instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

usersWithTwitterIDs:page:successBlock:errorBlock:

+ (QBRequest *)usersWithTwitterIDs:(NSArray<NSString*> *)twitterIDs page:(nullable QBGeneralResponsePage *)page successBlock:(nullable qb_response_users_block_t)successBlock errorBlock:(nullable qb_response_block_t)errorBlock
Discussion

Retrieve users with twitter ids (with extended set of pagination parameters)

Parameters

twitterIDs

Twitter IDs of users which you want to retrieve

page

Pagination parameters

successBlock

Block with response, page and users instances if request succeded

errorBlock

Block with response instance if request failed

Return Value

An instance of QBRequest for cancel operation mainly.

Declared In

QBRequest+QBUsers.h

Instance Methods

cancel

- (void)cancel
Discussion

Cancels NSURLSessionTask associated with request.

Declared In

QBRequest.h

init

- (instancetype)init