FINA Premises
FINA Premises
Manage business premises for FINA fiscalization
The FINA Premise object
Attributes
{
"id": "fina_premise_507f1f77bcf86cd799439011",
"entity_id": "ent_507f1f77bcf86cd799439011",
"business_premise_name": "PP1",
"type": "premise",
"real_estate": null,
"movable_premise": null,
"is_active": true,
"registered_at": "2025-01-01T00:00:00.000Z",
"closed_at": null,
"created_at": "2025-01-01T00:00:00.000Z",
"updated_at": "2025-01-01T00:00:00.000Z"
}Create business premise
/fiscalization/fina/premisesAdd a business premise for FINA fiscalization. The premise must be registered on ePorezna first. Only the premise ID label is stored.
Header parameters
Entity ID on which the request is made. Auto-selected when only one entity exists, required when multiple entities exist.
Body parameters
Business premise name (OznPosPr), alphanumeric, 1-20 chars. Must match the name registered on ePorezna.
import SpaceInvoices from '@spaceinvoices/js-sdk';
const sdk = new SpaceInvoices('YOUR_API_KEY');
const response = await sdk.finaPremises.create({
business_premise_name: "PP1",
starting_number: 100
});
console.log(response);Returns
Business premise name
{
"success": true,
"message": "Business premise created successfully",
"business_premise_name": "PP1"
}List business premises
/fiscalization/fina/premisesList all business premises for the entity
Header parameters
Entity ID on which the request is made. Auto-selected when only one entity exists, required when multiple entities exist.
import SpaceInvoices from '@spaceinvoices/js-sdk';
const sdk = new SpaceInvoices('YOUR_API_KEY');
const response = await sdk.finaPremises.listFinaPremises();
console.log(response);[]Get business premise
/fiscalization/fina/premises/{id}Get a single business premise by ID
Header parameters
Entity ID on which the request is made. Auto-selected when only one entity exists, required when multiple entities exist.
Path parameters
Premise ID
import SpaceInvoices from '@spaceinvoices/js-sdk';
const sdk = new SpaceInvoices('YOUR_API_KEY');
const response = await sdk.finaPremises.getFinaPremise('FINAPREMISES_ID');
console.log(response);Returns
{
"id": "fina_premise_507f1f77bcf86cd799439011",
"entity_id": "ent_507f1f77bcf86cd799439011",
"business_premise_name": "PP1",
"type": "premise",
"real_estate": null,
"movable_premise": null,
"is_active": true,
"registered_at": "2025-01-01T00:00:00.000Z",
"closed_at": null,
"created_at": "2025-01-01T00:00:00.000Z",
"updated_at": "2025-01-01T00:00:00.000Z"
}Update business premise
/fiscalization/fina/premises/{id}Update mutable FINA premise settings. The starting number can only be changed before invoices have been issued for the premise-level sequence.
Header parameters
Entity ID on which the request is made. Auto-selected when only one entity exists, required when multiple entities exist.
Path parameters
Premise ID
Body parameters
import SpaceInvoices from '@spaceinvoices/js-sdk';
const sdk = new SpaceInvoices('YOUR_API_KEY');
const response = await sdk.finaPremises.update('FINAPREMISES_ID', {
starting_number: 250
});
console.log(response);Returns
{
"id": "fina_premise_507f1f77bcf86cd799439011",
"entity_id": "ent_507f1f77bcf86cd799439011",
"business_premise_name": "PP1",
"type": "premise",
"real_estate": null,
"movable_premise": null,
"is_active": true,
"starting_number": 250,
"registered_at": "2025-01-01T00:00:00.000Z",
"closed_at": null,
"created_at": "2025-01-01T00:00:00.000Z",
"updated_at": "2025-01-02T00:00:00.000Z"
}Delete business premise
/fiscalization/fina/premises/{id}Deactivate a business premise and all its devices.
Header parameters
Entity ID on which the request is made. Auto-selected when only one entity exists, required when multiple entities exist.
Path parameters
Premise ID
import SpaceInvoices from '@spaceinvoices/js-sdk';
const sdk = new SpaceInvoices('YOUR_API_KEY');
await sdk.finaPremises.delete("fina_premise_abc123");
console.log('Deleted successfully');Returns
Business premise name
{
"success": true,
"message": "Business premise deactivated successfully",
"business_premise_name": "PP1"
}