ZXServerUrl.m 2.28 KB
//
//  ZXServerUrl.m
//  ZXBaseProject
//
//  Created by 张旭 on 2017/1/11.
//  Copyright © 2017年 cnlive. All rights reserved.
//

#import "ZXServerUrl.h"

#ifdef DEBUG
static NSString *serverBaseURL     = @"http://api.cnlive.com";//通用测试服务器域名
static NSString *serverChatBaseURL = @"http://120.92.4.46:8081";//聊天测试服务器域名
#else
static NSString *serverBaseURL     = @"https://perapi.svipmovie.com";//通用正式服务器域名
static NSString *serverChatBaseURL = @"https://perapi.svipmovie1.com";//聊天正式服务器域名
#endif

////////////////////////////////////////////////////////
////////////           具体请求接口URL
////////////////////////////////////////////////////////

/** 搜索页内容 */
static NSString *g_SearchContentURL = @"/from/huntKeyWordApi/huntKeyWords.do";//@"api/findMessage";//发现消息

/** 直播列表 */
static NSString *g_LiveListURL = @"/open/api2/live_epg/sp/activityList4App";

/** 直播活动详情 */
static NSString *g_LiveActivityInfoURL = @"/open/api2/live_epg/getLiveActivityPlayInfo4App";

/** 验证主播是否有直播权限 */
static NSString *g_VerifyLiveAuthURL = @"/open/api2/live_epg/channel/info4App";

@implementation ZXServerUrl

////////////////////////////////////////////////////////
////////////          BaseUrls
////////////////////////////////////////////////////////

/** 获取服务器baseUrl */
+ (NSString *)getServerBaseURL
{
    return serverBaseURL;
}

/** 获取聊天服务器baseUrl */
+ (NSString *)getServerChatBaseURL
{
    return serverChatBaseURL;
}

////////////////////////////////////////////////////////
////////////          BusinessUrls
////////////////////////////////////////////////////////

/** 搜索页内容 */
+ (NSString *)getSearchContentURL
{
    return [NSString stringWithFormat:@"%@%@", serverBaseURL, g_SearchContentURL];
}

/** 直播列表 */
+ (NSString *)getLiveListURL
{
    return [NSString stringWithFormat:@"%@%@", serverBaseURL, g_LiveListURL];
}

/** 直播活动详情 */
+ (NSString *)getLiveActivityInfoURL
{
    return [NSString stringWithFormat:@"%@%@", serverBaseURL, g_LiveActivityInfoURL];
}

/** 验证主播是否有直播权限 */
+ (NSString *)verifyLiveAuthURL
{
    return [NSString stringWithFormat:@"%@%@", serverBaseURL, g_VerifyLiveAuthURL];
}

@end