@lap v0.3
# Machine-readable API spec. Each @endpoint block is one API call.
@api Ntropy Transaction API v1
@base https://api.ntropy.network
@auth ApiKey
@endpoints 10
@toc classifier(7), types(1), health(1), performance(1)

@group classifier
@endpoint POST /classifier/consumer/batch
@desc Classify a batch of consumer transactions
@returns(202) {status: str, updated_at: str, id: str, progress: int, results: [map]}

@endpoint GET /classifier/consumer/batch/:id
@desc Get a batch of consumer transaction classification results
@required {id: str # (Required) Batch id.}

@endpoint POST /classifier/consumer
@desc Classify a consumer transaction
@required {transaction: map, user: map, device: map}

@endpoint POST /classifier/business/batch
@desc Classify a batch of business transactions
@returns(202) {status: str, updated_at: str, id: str, progress: int, results: [map]}

@endpoint GET /classifier/business/batch/:id
@desc Get a batch of business transaction classification results
@required {id: str # (Required) Batch id.}

@endpoint POST /classifier/business
@desc Classify a business transaction
@required {transaction: map, business: map, cardholder: map}
@returns(200) {transaction_id: str, logo: str, website: str, merchant: str, labels: [str]}

@endpoint POST /classifier/report
@desc Correct the output of the classifier
@required {transaction_id: str}

@endgroup

@group types
@endpoint GET /types
@desc Get dictionary of type values supported by Tranasction API
@returns(200) {moto_eci_code: [str], pan_entry_mode_auth: [str], pan_entry_mode_capture: [str]}

@endgroup

@group health
@endpoint GET /health
@desc Get the API health info

@endgroup

@group performance
@endpoint GET /performance
@desc Get the Transaction API performance report

@endgroup

@end
