Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ It has a fairly straightforward interface, essentially

::

mtd-cli init|init-creds|init-oauth|init-nino|bd|biss|bsas|cisd|ic|ical|icgi|id|idi|ie|iei|ifi|iipi|ilos|ioi|ipi|ir|isb|isi|itla|ob|od|pb|saa|saass|said|seb|vat|test_cu|test_fph|test_sa
mtd-cli init|init-creds|init-oauth|init-nino|bd|biss|bsas|cisd|ic|ical|icgi|id|idi|ie|iei|ifi|iipi|il|ioi|ipi|ir|isb|isi|itla|ob|od|pb|saa|saass|said|seb|vat|test_cu|test_fph|test_sa

The first argument specifies the API to interface with

Expand Down
2 changes: 1 addition & 1 deletion src/endpoints.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ extern const struct _endpoint ie_endpoint;
extern const struct _endpoint iei_endpoint;
extern const struct _endpoint ifi_endpoint;
extern const struct _endpoint iipi_endpoint;
extern const struct _endpoint ilos_endpoint;
extern const struct _endpoint il_endpoint;
extern const struct _endpoint ioi_endpoint;
extern const struct _endpoint ipi_endpoint;
extern const struct _endpoint ir_endpoint;
Expand Down
47 changes: 47 additions & 0 deletions src/mtd-cli-il.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
/* SPDX-License-Identifier: GPL-2.0 */

/*
* mtd-cli-il.c - Make Tax Digital - Individuals Losses
*
* Copyright (C) 2020 - 2026 Andrew Clayton <ac@sigsegv.uk>
*/

#include <stdbool.h>

#include <libmtdac/mtd.h>

#include "mtd-cli.h"

#define API il

#define API_NAME "Individuals Losses"
#define CMDS \
"get amend delete\n\n"\

Comment thread
ac000 marked this conversation as resolved.
static const struct endpoint endpoints[] = {
{
.name = "get",
.api_ep = MTD_API_EP_IL_GET,
.nr_req_args = 2,
.args = "businessId taxYear"
}, {
.name = "amend",
.api_ep = MTD_API_EP_IL_AMEND,
.nr_req_args = 3,
.file_data = true,
.args = "<file> businessId taxYear"
}, {
.name = "delete",
.api_ep = MTD_API_EP_IL_DELETE,
.nr_req_args = 2,
.args = "businessId taxYear"
},

{ }
};

const struct _endpoint ENDPOINT = {
.endpoints = endpoints,
.api_name = API_NAME,
.cmds = CMDS
};
98 changes: 0 additions & 98 deletions src/mtd-cli-ilos.c

This file was deleted.

2 changes: 1 addition & 1 deletion src/mtd-cli.c
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ static const struct api_ep {
EP_MAP_ENT(iei),
EP_MAP_ENT(ifi),
EP_MAP_ENT(iipi),
EP_MAP_ENT(ilos),
EP_MAP_ENT(il),
EP_MAP_ENT(ioi),
EP_MAP_ENT(ipi),
EP_MAP_ENT(ir),
Expand Down
Loading