curl --request GET \
--url https://api.baselayer.com/lien_submissions/import/batches \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.baselayer.com/lien_submissions/import/batches"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.baselayer.com/lien_submissions/import/batches', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.baselayer.com/lien_submissions/import/batches",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.baselayer.com/lien_submissions/import/batches"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.baselayer.com/lien_submissions/import/batches")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.baselayer.com/lien_submissions/import/batches")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "q3-portfolio-liens.csv",
"state": "PENDING",
"total_count": 100,
"created_at": "2023-11-07T05:31:56Z",
"completed_count": 0,
"progress": 0,
"imported_count": 80,
"already_imported_count": 15,
"not_found_count": 4,
"invalid_row_count": 1,
"error": "The uploaded CSV could not be read from storage."
}
]{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}List Lien Filing Import Batches
Lists the bulk lien import batches visible to the caller, most recently created first.
curl --request GET \
--url https://api.baselayer.com/lien_submissions/import/batches \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.baselayer.com/lien_submissions/import/batches"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.baselayer.com/lien_submissions/import/batches', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.baselayer.com/lien_submissions/import/batches",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.baselayer.com/lien_submissions/import/batches"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.baselayer.com/lien_submissions/import/batches")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.baselayer.com/lien_submissions/import/batches")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "q3-portfolio-liens.csv",
"state": "PENDING",
"total_count": 100,
"created_at": "2023-11-07T05:31:56Z",
"completed_count": 0,
"progress": 0,
"imported_count": 80,
"already_imported_count": 15,
"not_found_count": 4,
"invalid_row_count": 1,
"error": "The uploaded CSV could not be read from storage."
}
]{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
Query Parameters
Maximum number of records to return in a single page. Must be between 1 and 1000.
1 <= x <= 1000Number of records to skip from the beginning. Use 0 for the first page. Cannot be used with cursor.
x >= 0Opaque pagination cursor token that identifies the position in the result set. Use the cursor from the previous response to get the next page. Cannot be used with offset.
Response
List of bulk lien import batches.
The batch's id, used to poll status and fetch per-row results.
The name of the batch, taken from the uploaded file.
"q3-portfolio-liens.csv"
Processing state of the batch.
PENDING, EXECUTING, COMPLETED, FAILED, CANCELLED "PENDING"
Rows read from the uploaded CSV, excluding blank lines.
100
When the batch was accepted.
Rows processed so far, whatever their outcome — the sum of the four outcome counts.
0
50
Fraction of the uploaded rows processed so far, in [0, 1].
0
0.5
1
Rows that resolved against the public record and produced a newly imported filing.
80
Rows naming a lien the organization had already imported; the existing filing is kept.
15
Rows whose state and filing number matched nothing in the public record.
4
Rows rejected before resolution (unparseable state, blank filing number, and the like).
1
Why the batch last failed, as a human-readable message. Set when the state is FAILED; a batch that failed once and succeeded on a resume can still carry the message from that attempt, so read it alongside the state rather than as a failure signal on its own.
"The uploaded CSV could not be read from storage."