Developer Documentation

API Reference

Build integrations with the JoshSecLogs REST API. All endpoints are JSON-based and authenticated with JWT or API keys.

Quick Start

All API requests are made to https://api.joshseclogs.com/api/v1. Authenticate by including your JWT token or API key in the Authorization header.

Example Request
curl -X GET https://api.joshseclogs.com/api/v1/marketplace/countries \
  -H "Authorization: Bearer YOUR_API_KEY"

Authentication

Use the JWT access token from /auth/login or generate an API key from your dashboard. Include it as a Bearer token in the Authorization header for all authenticated requests.

Response Format

All responses are JSON. Successful responses return the data directly or wrapped in { data: ... }. Errors return { statusCode, message } with appropriate HTTP status codes.

Endpoints

POST/auth/register

Create a new user account. Returns the user object.

POST/auth/login

Authenticate with email and password. Returns a JWT access token.

GET/auth/me

Get the authenticated user's profile.

Auth
PATCH/auth/me

Update the authenticated user's name and email.

Auth
PATCH/auth/me/password

Change password. Requires currentPassword and newPassword.

Auth
GET/marketplace/countries

List all available countries for virtual numbers.

Auth
GET/marketplace/products/:country

List available products/services for a given country.

Auth
GET/marketplace/prices/:country

Get pricing for all services in a country, including stock counts.

Auth
POST/marketplace/buy

Purchase a virtual number. Deducts from wallet balance.

Auth
GET/marketplace/orders

List all orders for the authenticated user.

Auth
GET/marketplace/orders/:id/sms

Get SMS messages received on a specific order's number.

Auth
POST/marketplace/orders/:id/finish

Finish an order (confirm SMS received).

Auth
POST/marketplace/orders/:id/cancel

Cancel an order. Refunds the wallet if SMS was not received.

Auth
GET/social-logs/categories

List all social log categories.

Auth
GET/social-logs

List available social logs. Optional ?category= filter.

Auth
GET/social-logs/:id

Get full details of a social log (including credentials after purchase).

Auth
POST/social-logs/:id/purchase

Purchase a social log. Deducts from wallet and assigns to buyer.

Auth
GET/social-logs/my-purchases

List all social logs purchased by the authenticated user.

Auth
GET/wallet

Get the authenticated user's wallet balance.

Auth
GET/wallet/transactions

List wallet transaction history.

Auth
POST/payments/initialize

Initialize a Paystack payment to fund the wallet.

Auth
POST/payments/verify

Verify a Paystack payment and credit the wallet.

Auth
GET/api-keys

List the authenticated user's API keys (masked).

Auth
POST/api-keys

Generate a new API key. Returns the full key once.

Auth
DELETE/api-keys/:id

Delete an API key permanently.

Auth

Need an API Key?

Generate API keys from your dashboard after registering.

Create Account