As of iOS 7, use of the microphone requires permission from the user. Unfortunately, the first time you put the audio session category into AVAudioSessionPlayAndRecord the user will get the familiar (some may say startling) permission prompt.

It is suggested to ease the prompt on the user, to provide some explanation as to why they should accept. This can be done programmatically.

- (void)checkMicrophonePermissions
{
    //Example Workflow for Microphone Usage
    if ([AVCaptureDevice respondsToSelector:@selector(authorizationStatusForMediaType:)]) {

        AVAuthorizationStatus authorizationStatus = [AVCaptureDevice authorizationStatusForMediaType:AVMediaTypeAudio];

        if (authorizationStatus == AVAuthorizationStatusAuthorized) {
            //Everything is good.
        } else {

            switch (authorizationStatus) {
                case AVAuthorizationStatusNotDetermined:
                {
                    //Ok, ask for permission
                    [self requestPermission];
                }
                break;

                case AVAuthorizationStatusDenied:
                {
                    //The user has denied access, XappAds will not run
                }
                break;

                default:
                    break;
            }
        }

    } else {
        //It is iOS 6, microphone permission doesn't matter
    }
}

- (void)requestPermission
{
    [[AVAudioSession sharedInstance] requestRecordPermission:^(BOOL granted) {
        if (granted) {
            NSLog(@"Permission Granted");
            //Everything is good.
        } else {
            NSLog(@"Permision Denied");
            //Permission denied, XappAds will not operate
       }
    }];
}