Customers API Guide

This guide documents the API endpoints for managing your Tips Feed package.

Base URL: https://engage-api.lsports.eu/api/tips

All endpoints require authentication via the username and password fields in the request body. Credentials are validated against your stored package credentials.


Endpoints

1. Activate Package

Activates a Tips Feed package. Validates credentials and updates the package status to active in the database.

POST https://engage-api.lsports.eu/api/tips/package/activate

Request body

{
  "packageId": 123,
  "username": "[email protected]",
  "password": "password123"
}

Success (200)

{
  "success": true,
  "message": "Package activation completed successfully",
  "packageId": 123,
  "username": "[email protected]"
}

If the package is already active, the API returns success with the message "Package is already active".

Validation Error (400)

Possible validation errors:

  • "PackageId must be a positive integer"

  • "Username is required"

  • "Password is required"

  • "Invalid package credentials"

Server Error (500)

cURL


2. Deactivate Package

Deactivates a Tips Feed package. Validates credentials and updates the package status to inactive in the database.

Request body

Success (200)

If the package is already inactive, the API returns success with the message "Package is already inactive".

Validation Error (400)

Possible validation errors:

  • "PackageId must be a positive integer"

  • "Username is required"

  • "Password is required"

  • "Invalid package credentials"

Server Error (500)

cURL


3. Get Package Status

Retrieves the current status of a Tips Feed package without modifying it. Returns whether the package is active or inactive.

Request body

Success (200)

The status field can be either "active" or "inactive".

Validation Error (400)

Possible validation errors:

  • "PackageId must be a positive integer"

  • "Username is required"

  • "Password is required"

  • "Invalid package credentials"

Server Error (500)

cURL


Authentication

All endpoints require authentication via the username and password fields in the request body. The credentials are validated against the stored package credentials in the database.


Error Handling

Validation Errors (400) — Returned when:

  • Required fields are missing or invalid

  • Package credentials do not match

  • Package does not exist

Server Errors (500) — Returned when:

  • Database connection fails

  • External API calls fail

  • Unexpected server-side errors occur

Last updated

Was this helpful?