definitions: domain.Odd: properties: category: type: string event_id: type: string fetched_at: type: string fi: type: string handicap: type: string id: type: integer is_active: type: boolean market_category: type: string market_id: type: string market_name: type: string market_type: description: RawEventID string `json:"raw_event_id"` type: string name: description: Header string `json:"header"` type: string odds_value: type: number raw_odds: items: {} type: array section: type: string source: type: string type: object domain.RawOddsByID: properties: event_id: type: string fetched_at: type: string id: type: integer raw_odds: items: {} type: array type: object domain.Role: enum: - super_admin - admin - branch_manager - customer - cashier type: string x-enum-varnames: - RoleSuperAdmin - RoleAdmin - RoleBranchManager - RoleCustomer - RoleCashier handlers.CheckPhoneEmailExistReq: properties: email: example: john.doe@example.com type: string phone_number: example: "1234567890" type: string type: object handlers.CheckPhoneEmailExistRes: properties: email_exist: type: boolean phone_number_exist: type: boolean type: object handlers.RegisterCodeReq: properties: email: example: john.doe@example.com type: string phone_number: example: "1234567890" type: string type: object handlers.RegisterUserReq: properties: email: example: john.doe@example.com type: string first_name: example: John type: string last_name: example: Doe type: string otp: description: Role string example: "123456" type: string password: example: password123 type: string phone_number: example: "1234567890" type: string referal_code: example: ABC123 type: string type: object handlers.ResetCodeReq: properties: email: example: john.doe@example.com type: string phone_number: example: "1234567890" type: string type: object handlers.ResetPasswordReq: properties: email: type: string otp: type: string password: type: string phoneNumber: type: string type: object handlers.UserProfileRes: properties: created_at: type: string email: type: string email_verified: type: boolean first_name: type: string id: type: integer last_name: type: string phone_number: type: string phone_verified: type: boolean role: $ref: '#/definitions/domain.Role' suspended: type: boolean suspended_at: type: string updated_at: type: string type: object handlers.loginCustomerReq: properties: email: example: john.doe@example.com type: string password: example: password123 type: string phone_number: example: "1234567890" type: string type: object handlers.loginCustomerRes: properties: access_token: type: string refresh_token: type: string type: object handlers.logoutReq: properties: refresh_token: type: string type: object handlers.refreshToken: properties: access_token: type: string refresh_token: type: string type: object response.APIResponse: properties: data: {} message: type: string metadata: {} status: $ref: '#/definitions/response.Status' timestamp: type: string type: object response.Status: enum: - error - success type: string x-enum-varnames: - Error - Success info: contact: email: support@swagger.io name: API Support url: http://www.swagger.io/support description: This is server for FortuneBet. license: name: Apache 2.0 url: http://www.apache.org/licenses/LICENSE-2.0.html termsOfService: http://swagger.io/terms/ title: FortuneBet API version: "1.0" paths: /auth/login: post: consumes: - application/json description: Login customer parameters: - description: Login customer in: body name: login required: true schema: $ref: '#/definitions/handlers.loginCustomerReq' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/handlers.loginCustomerRes' "400": description: Bad Request schema: $ref: '#/definitions/response.APIResponse' "401": description: Unauthorized schema: $ref: '#/definitions/response.APIResponse' "500": description: Internal Server Error schema: $ref: '#/definitions/response.APIResponse' summary: Login customer tags: - auth /auth/logout: post: consumes: - application/json description: Logout customer parameters: - description: Logout customer in: body name: logout required: true schema: $ref: '#/definitions/handlers.logoutReq' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/response.APIResponse' "400": description: Bad Request schema: $ref: '#/definitions/response.APIResponse' "401": description: Unauthorized schema: $ref: '#/definitions/response.APIResponse' "500": description: Internal Server Error schema: $ref: '#/definitions/response.APIResponse' summary: Logout customer tags: - auth /auth/refresh: post: consumes: - application/json description: Refresh token parameters: - description: tokens in: body name: refresh required: true schema: $ref: '#/definitions/handlers.refreshToken' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/handlers.loginCustomerRes' "400": description: Bad Request schema: $ref: '#/definitions/response.APIResponse' "401": description: Unauthorized schema: $ref: '#/definitions/response.APIResponse' "500": description: Internal Server Error schema: $ref: '#/definitions/response.APIResponse' summary: Refresh token tags: - auth /prematch/odds: get: consumes: - application/json description: Retrieve all prematch odds from the database produces: - application/json responses: "200": description: OK schema: items: $ref: '#/definitions/domain.Odd' type: array "500": description: Internal Server Error schema: $ref: '#/definitions/response.APIResponse' summary: Retrieve all prematch odds tags: - prematch /prematch/odds/{event_id}: get: consumes: - application/json description: Retrieve prematch odds for a specific event by event ID parameters: - description: Event ID in: path name: event_id required: true type: string produces: - application/json responses: "200": description: OK schema: items: $ref: '#/definitions/domain.Odd' type: array "400": description: Bad Request schema: $ref: '#/definitions/response.APIResponse' "500": description: Internal Server Error schema: $ref: '#/definitions/response.APIResponse' summary: Retrieve prematch odds for an event tags: - prematch /prematch/odds/raw/{raw_odds_id}: get: consumes: - application/json description: Retrieve raw odds by raw odds ID parameters: - description: Raw Odds ID in: path name: raw_odds_id required: true type: string produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/domain.RawOddsByID' "400": description: Bad Request schema: $ref: '#/definitions/response.APIResponse' "500": description: Internal Server Error schema: $ref: '#/definitions/response.APIResponse' summary: Retrieve raw odds by ID tags: - prematch /user/checkPhoneEmailExist: post: consumes: - application/json description: Check if phone number or email exist parameters: - description: Check phone number or email exist in: body name: checkPhoneEmailExist required: true schema: $ref: '#/definitions/handlers.CheckPhoneEmailExistReq' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/handlers.CheckPhoneEmailExistRes' "400": description: Bad Request schema: $ref: '#/definitions/response.APIResponse' "500": description: Internal Server Error schema: $ref: '#/definitions/response.APIResponse' summary: Check if phone number or email exist tags: - user /user/profile: get: consumes: - application/json description: Get user profile produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/handlers.UserProfileRes' "400": description: Bad Request schema: $ref: '#/definitions/response.APIResponse' "500": description: Internal Server Error schema: $ref: '#/definitions/response.APIResponse' security: - Bearer: [] summary: Get user profile tags: - user /user/register: post: consumes: - application/json description: Register user parameters: - description: Register user in: body name: registerUser required: true schema: $ref: '#/definitions/handlers.RegisterUserReq' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/response.APIResponse' "400": description: Bad Request schema: $ref: '#/definitions/response.APIResponse' "500": description: Internal Server Error schema: $ref: '#/definitions/response.APIResponse' summary: Register user tags: - user /user/resetPassword: post: consumes: - application/json description: Reset password parameters: - description: Reset password in: body name: resetPassword required: true schema: $ref: '#/definitions/handlers.ResetPasswordReq' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/response.APIResponse' "400": description: Bad Request schema: $ref: '#/definitions/response.APIResponse' "500": description: Internal Server Error schema: $ref: '#/definitions/response.APIResponse' summary: Reset password tags: - user /user/sendRegisterCode: post: consumes: - application/json description: Send register code parameters: - description: Send register code in: body name: registerCode required: true schema: $ref: '#/definitions/handlers.RegisterCodeReq' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/response.APIResponse' "400": description: Bad Request schema: $ref: '#/definitions/response.APIResponse' "500": description: Internal Server Error schema: $ref: '#/definitions/response.APIResponse' summary: Send register code tags: - user /user/sendResetCode: post: consumes: - application/json description: Send reset code parameters: - description: Send reset code in: body name: resetCode required: true schema: $ref: '#/definitions/handlers.ResetCodeReq' produces: - application/json responses: "200": description: OK schema: $ref: '#/definitions/response.APIResponse' "400": description: Bad Request schema: $ref: '#/definitions/response.APIResponse' "500": description: Internal Server Error schema: $ref: '#/definitions/response.APIResponse' summary: Send reset code tags: - user securityDefinitions: Bearer: in: header name: Authorization type: apiKey swagger: "2.0"