Giter Club home page Giter Club logo

boxtech's Introduction

Introduction

Boxtech provides container technical detail for the global container fleet, you can see what data is available in our dataset, we would recommend that you use the API for integrating to your application as well as the user interface for less frequent lookups.

The documentation is available at https://docs.bic-boxtech.org

Full details on Boxtech and the BIC can be found at https://www.bic-boxtech.org

For feature requests, support or other requests please raise a github issue at https://github.com/bic-org/Boxtech and we will reply accordingly.

Register for Access

Access to Boxtech is free, you just need to register to use the service and verify your email account.

Registration can be found at https://app.bic-boxtech.org/sign-up

User Roles

You can use Boxtech as either:

  • Consumer
  • Uploader

Consumers

As a consumer you get full access to Boxtech to query the containers in the database, you only need the container number you are looking for and you can search using the web interface for occasional use OR use the API to integrate or script queries to Boxtech from your own application.

You will need to register to gain access, and can start using the application immediately.

Uploaders

To add your containers to boxtech and manage your fleet or apply container alerts to containers you will need to have uploader rights. To qualify for this you will need to register as an uploader in Boxtech and provide the BIC prefix that applies to you.

This information is verified by BIC and once approved you will have the ability to start managing your container fleet and alerts.

You will gain immediate access to Boxtech as a consumer but only have uploader rights until verification has taken place by the BIC team.

When registering for Boxtech provide one of your BIC codes and we will verify your account as part of your application to become an uploader.

If you are already registered as a consumer then, once logged into Boxtech you can request access by clicking the button below and providing a BIC Code.

Follow the Getting Started guide to uploading your fleet

API Specifications

All Our API's are published on SwaggerHub https://app.swaggerhub.com/apis/BIC-ORG

Download the Postman Collection from https://documenter.getpostman.com/view/Tzm9huBX

Issues, Support or Feature Requests

We are always interested to hear your ideas for Boxtech, and to support your journey to integrating Boxtech into your systems. Please raise a Github issue for us to manage these requests and we will be happy to assist. and hear from you.

https://github.com/bic-org/Boxtech

boxtech's People

Contributors

altiusrupert avatar berniersfcloud avatar bic-boxtech avatar cmsdroff avatar declanoconnor avatar dependabot[bot] avatar lewis-david-wong avatar pierrickbrun avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

boxtech's Issues

How to get OAth Token with HttpClient?

I need to use HttpClient for the request. But I don't know how to get the token.

Here is the way I tried it:

private async void GetBicDataAsync()
    {
        HttpClient _bicAothClient;

        _bicAothClient = new HttpClient();
        _bicAothClient.DefaultRequestHeaders.Add("Authorization", "Basic YmljYXBwOmJpY3NlY3JldGFwcA==");

        var content = new FormUrlEncodedContent(new[]
        {
            new KeyValuePair<string, string>("grant_type", "password"),
            new KeyValuePair<string, string>("username", Constants.BicAothUser),
            new KeyValuePair<string, string>("password", Constants.BicAothPassword)
        });

        var result = await _bicAothClient.PostAsync("http://app.bic-boxtech.org/oauth/token", content);
    }

But when I use

var contentString = await result.Content.ReadAsStringAsync();

the result is

{"statusCode":400,"status":400,"code":400,"message":"Invalid request: method must be POST","name":"invalid_request"}

What did I wrong. I thing it's a small stupid fail. Can someone help me please.

Issue with getting the token

Hi All,

First, thank you for developing this tool. I believe this could be really useful. I was having some trouble getting the access token. I've followed the instructions for the 'Getting Started' guide and this is the response I get when clicking the 'Send' button:

{ "statusCode": 400, "status": 400, "code": 400, "message": "Invalid grant: user credentials are invalid", "name": "invalid_grant" }

I have a reader user on BoxTech.

Could you help me out with this?
Thank you,
Ignacio

Query Limit

Hi,

Just tried running the API to update the container details in our Database and it says i've already hit the limit of 100 per "abcd" container for the day.
Is there any plans to remove the limit ?

Thanks

Use a permanent token

Hi,

I have successfully get an access token and I have made some GET requests without any problem. However, after some time I started getting these responses:

{'statusCode': 401, 'status': 401, 'code': 401, 'message': 'Invalid token: access token has expired', 'name': 'invalid_token'}

I want to deploy my application in Production, how can I get a permanent token?

Regards!

response as json

We are interested to know as much information on the containers before they arrive at Terminal (for a correct vessel/yard planning) because when they enter/dishcharge will be inspected by us from our checker. Also the ROB (vessel remain on the board) container we need to know as much information.
We are looking for tare weight, max gross weight and iso syze-type code.
We use already many tools/data-flows to obtain this information. We want to integrate new tools…
We use kg.

Linked Data Topic

Adding comments here from DCSA repo dcsaorg/DCSA-OpenAPI#142

We are looking int the linked data for Boxtech and other BIC resources (i.e. facility codes) so this is on the roadmap, ticket open here for thoughts from others and to track discussion.

Boxtech could provide if the BIC Code is valid and registered as well as container door info on a linked data url like this, welcome input to shape this work.

Picture 1

I cannot call service

I keep getting this response:

Invalid grant: user credentials are invalid

I logged in/out with the same password successfully. However, the service does not accept it. Should it be a different password?

Regards,

Upload Fleet to Boxtech by API

Dear All,

Following some increased interest in uploading container fleets to Boxtech by API, we will be implementing this feature into the platform,

Our draft Open API Spec can be found at https://app.swaggerhub.com/apis/BIC-ORG/Boxtech/2.0.2-postContainer

New features to the API will be:

The schema has also been enhanced to cover where available:

  • Combined Safety Plate
  • Smart Container and Certification Type
  • Tank Container Details

Would welcome your input on the API changes, any additions you would like to make or suggestion

Best Regards

David

[Question] Empty 200 response for /container/{containerNumber}

We have a container number EXFU8211118 which we wanted to retrieve information on and while we get a 200 OK response we do get an empty body ('{}').

image

Question is why this happens? And can we rely on the 200 OK to confirm that this is a valid number even though we get an empty response?

Incomplete data

Hello,
I work in a seaport and my job is to check the identity and especially the size of the containers.
Each month we work on a minimum of 15 000 containers.
So you understand that the volume is important.

I have integrated the API in our management software and out of the total number of containers we operate, 7% do not have a size and 44% are not in the BIC database, this is the problem we encounter during the monthly verifications.

It seems that the BIC either doesn't update the database anymore, or the API limits the results it displays.

44% I think is a very high value for a Global database.
The idea of setting up the API is really good, but not all containers are available on the BIC database.

If you can help by updating your database that would be very encouraging.
If you need more elements to process this request I remain fully available to help.

some information missed

excuse me

when i use the api "https://api.bic-boxtech.org/api/v2.0/codes/AAAU"

the return result is "
[
{
"code": "AAAU",
"name": "ASIA CONTAINER LEASING CO LTD",
"address": {
"country": "Hong Kong, China"
}
}
]
"

miss some information.

### this is your example request

[
{
"code": "AAAU",
"name": "ASIA CONTAINER LEASING CO LTD",
"address": {
"street": "RM 2310, DOMINION CENTRE\n 43-59 QUEENS ROAD EAST",
"city": "WAN CHAI",
"postCode": "",
"country": "Hong Kong, China"
},
"phone": "+852 2521 0859",
"fax": "+852 2521 1978",
"website": "www.asia-container.com"
}
]

Endpoint for Owner ID

It would be nice to have an endpoint to get the cleartext name of an owners´s ID.

Container Alerts?

In the swagger definition, there is nested json for alerts:

type string
description string
message string

Is there any documentation of what values of type can be?

HTTP 400 reCAPTCHA Error

Hello,

Following the BIC Boxtech API Get Started here results in an HTTP 400 (Bad Request) error when attempting to retrieve the API access token:

{"message":"CAPTCHA does not match"}

Could you provide more information on how to resolve this? Thank you!

REST API to lookup the tare weight of a container

Set up an API to look up the tare weight of a container.

This is a REST API. Authentication is through OAuth2.

Parameters for the request are the container number, as well as the requested weight unit (kgs, lbs).
The answer is the weight, a decimal value in kgs or lbs. Decimal point is a '.'.

Error codes :

  • authentication error : standard web REST codes
  • container not present in the TCD database

Boxtech - Upgrade Notice

Dear Boxtech users,

We are pushing some changes to the inner workings of Boxtech which improve performance for larger file uploads and will make it easier for fleet owners to update Boxtech in an autonomous way via SFTP and API. All unit tests pass and API responses are consistent with the current working of Boxtech so we are not foreseeing any disruption, however if you experience anything please comment on the thread here and we will be monitoring and responding if needed.

Changes will be live on the 24th February

Appreciate your support and Feedback

Is there an endpoint for Max payload?

Hi,
I wanted to ask whether it is already possible to get the Max payload field via API ?
Or would it be possible to fill Max gross mass by as the sum of tare and payload ?

Thanks in advance,
Regards,
Jc

Boxtech - Migrating Service - Friday 30th 14:00 CET - ACTION REQUIRED.

Hi All,

We are near completion of moving Boxtech to a Serverless environment and have made some changes to improve the experience, data quality, security and visual appearance of Boxtech.

To make the transition to the new environment simple and hopefully seamless we have retained the API Auth, and Endpoints that are in use, and we would like to request that you test your application in our UAT environment, this will be available from Monday 12th June until we make the changeover.

IMPORTANT

As part of our security review you will be required to change your password to access Boxtech, so please take this opportunity to test and engage with us during the UAT. It is planned that we will make the switchover for the end of July. Final date will be communicated here following external testing phase.

What we are looking for from you

Please register for the UAT environment:
https://uat.bic-code.org/sign-up

Please test your application on the UAT url with your API
https://uat.bic-boxtech.org/api/v2.0

We would really like you to test the API within your application to ensure a smooth transition, please pay attention to:

  • Authentication - by changing the URL to UAT can you authenticate and access Boxtech?
  • Endpoints - Please test all the endpoints you have coded into your application and confirm or advise if there are issues or differences in what you expect
  • Dataset are all the fields that you are using contained within the response? some fields from the /web endpoint and from alert response were designed to facilitate the Boxtech frontend only, you should be using /api endpoints only, these fields have been removed from the response.

Please raise any issues as GitHub issues or comments on this ticket so we can address and facilitate a smooth transition for your systems

Notes

We didn't want to issue a breaking change to the API version so it will remain at V2, however as noted above some fields contained icons or visual code from the web/endpoints which were used in the frontend, there should not have been any need or use for these and the web/ endpoint was internal, however it is important to check the responses are working in your applications to avoid any issues, please report by way of GitHub issue if this is problematic.

Some attributes were also using inconsistent formatting i.e. underscores or camelCase, we have standardised on the _ and added in values to replace these, so camelCase attributes will eventually be deprecated in a future V3, but V2 will have both versions in with the recommendation to use the _ value.

example:
checkDigitwarning
recommended to use
check_digit_warning

Swagger Spec

The swagger spec can be found at https://app.swaggerhub.com/apis/BIC-ORG/Boxtech/2.0.2-dev

Whilst your looking

We would really like to understand how Boxtech helps you and any feature requests you may have for Boxtech which maybe useful. This is a first step to bring Boxtech into the revised digital offering from BIC along with the BIC Facility Codes (https://www.bic-code.org/bic-facility-codes/) to uniquely identify container facilities and BIC Code Owner API.

Your feedback helps us shape the BIC API's to support your needs, thanks in advance for your support.

no-such-app

Hello, i have tried with postman with the test endpoint but heroku catch an error

no-such-app...

What is wong ?

Stefano

API answers with wrong content

Hi, I'm trying to use the API to get information about a container, but the answer is always HTML, not JSON.

Log:
Sending 'POST' request to URL : https://app.bic-boxtech.org/oauth/token
2018-08-24 12:52:30,299 [INFO] BicBoxtechService - Response Code : 200
2018-08-24 12:52:30,648 [INFO] BicBoxtechService -
Sending 'GET' request to URL : https://app.bic-boxtech.org/api/container/GLDU5334260
2018-08-24 12:52:30,648 [INFO] BicBoxtechService - Response Code : 200
2018-08-24 12:52:35,876 [ERROR] BicBoxtechService - Error when trying to get container data from BIC. The answer was not JSON.

The answer from the server:

<title>No such app</title> <style media="screen"> html, body, iframe { margin: 0; padding: 0; }
html, body {
    height: 100%;
    overflow: hidden;
}

iframe {
    width: 100%;
    height: 100%;
    border: 0;
}        </style>
<iframe src="//www.herokucdn.com/error-pages/no-such-app.html"></iframe>

What is wrong here? According to your API documentation, this should work.

Authentication error

I can successfully login into the Global Container Database website with my e-mail and password. But when I try to Get Token (https://d2u85ll8i89w2f.cloudfront.net) I have the
 error 400
"message": "Invalid grant: user credentials are invalid"
The credentials to use API are different from the ones to login in website?

Cannot get JSON output

I am able to retrieve my auth token and submit a curl GET for a BIC Code, but the API returns some <!doctype html> data and I cannot see the JSON output described in the documentation.

I've tried with both curl and Postman and tried tweaking the "Accept" parameters. I notice an error from Cloudflare but I am sure it is something more simple than that. Here is the erbose curl output:

kenneths-mbp:~ kennylane$ curl -v --location 'https://api.bic-boxtech.org/api/v2.0/codes/MNBU' --header 'Authorization: '

  • Trying 104.26.6.83:443...
  • Connected to api.bic-boxtech.org (104.26.6.83) port 443
  • ALPN: curl offers h2,http/1.1
  • (304) (OUT), TLS handshake, Client hello (1):
  • CAfile: /etc/ssl/cert.pem
  • CApath: none
  • (304) (IN), TLS handshake, Server hello (2):
  • (304) (IN), TLS handshake, Unknown (8):
  • (304) (IN), TLS handshake, Certificate (11):
  • (304) (IN), TLS handshake, CERT verify (15):
  • (304) (IN), TLS handshake, Finished (20):
  • (304) (OUT), TLS handshake, Finished (20):
  • SSL connection using TLSv1.3 / AEAD-AES256-GCM-SHA384
  • ALPN: server accepted h2
  • Server certificate:
  • subject: CN=bic-boxtech.org
  • start date: Mar 10 21:02:47 2024 GMT
  • expire date: Jun 8 21:02:46 2024 GMT
  • subjectAltName: host "api.bic-boxtech.org" matched cert's "*.bic-boxtech.org"
  • issuer: C=US; O=Google Trust Services LLC; CN=GTS CA 1P5
  • SSL certificate verify ok.
  • using HTTP/2
  • [HTTP/2] [1] OPENED stream for https://api.bic-boxtech.org/api/v2.0/codes/MNBU
  • [HTTP/2] [1] [:method: GET]
  • [HTTP/2] [1] [:scheme: https]
  • [HTTP/2] [1] [:authority: api.bic-boxtech.org]
  • [HTTP/2] [1] [:path: /api/v2.0/codes/MNBU]
  • [HTTP/2] [1] [user-agent: curl/8.4.0]
  • [HTTP/2] [1] [accept: /]
  • [HTTP/2] [1] [authorization:

GET /api/v2.0/codes/MNBU HTTP/2
Host: api.bic-boxtech.org
User-Agent: curl/8.4.0
Accept: /
Authorization:

< HTTP/2 200
< date: Tue, 30 Apr 2024 15:21:46 GMT
< content-type: text/html
< last-modified: Thu, 25 Apr 2024 13:56:50 GMT
< x-amz-server-side-encryption: AES256
< vary: Accept-Encoding
< x-cache: Error from cloudfront
< via: 1.1 d1dad7d3c339d87d553c26a84c9ca5d2.cloudfront.net (CloudFront)
< x-amz-cf-pop: IAD55-P4
< x-amz-cf-id: VQDfwgAOj4ffjTQlqWrTnQRZ5nlZcHvqjo5VWnJ15nI9zGi7SPHFyg==
< age: 229
< cf-cache-status: DYNAMIC
< report-to: {"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s="}],"group":"cf-nel","max_age":604800}
< nel: {"success_fraction":0,"report_to":"cf-nel","max_age":604800}
< server: cloudflare
< cf-ray: 87c885fdcf8482e1-IAD
<
<!doctype html>

<title>BIC Boxtech | Global Container Database</title> <script> var global = global || window; </script> <script src="runtime.0e49e2b53282f40c8925.js" defer></script><script src="polyfills.1718efd41ef073f31ae1.js" defer></script><script src="main.4fe9904d6bc977e35936.js" defer></script> * Connection #0 to host api.bic-boxtech.org left intact

General Question on data coverage

Hello,

we're currently implementing box tech inside a container tracking solution.
One key part we're interested in is the containers age, given by the manufacturing date.

The Boxtech api spec defines this field, however all containers we tried so far (primarily MSC / SEACO) retured a null value.

Could you give us a hint, how the current coverage of data is inside the Boxtech DB? This would help us to understand if the missing values a just a result of our subset of containers or if the carriers generally do not provide this data.

Also, is there another API for CSC Plate Info?

Best regards &
keep up the good work!

Last updated

Hello,
Do you have (looking at payload I can't find it) or plan to have a field that indicates when was the last time when data was updated for a specific container that is returned in the resultset?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.