Comments (7)
Hey @zeiler and @rok-povsic, thank you for providing the api endpoints and examples.
We are looking at ways to present to users, based on their role, what model
options should be available to them. The goal is to allow users to select their
desired app, and subsequently, to select models from the list of all custom
and built-in models in that app.
from clarifai-python.
Hi @jubins ,
The easiest value to get is the CUSTOM MODELS
one. This is len(self.models.get_all(private_only=True))
.
The other values cannot be accessed with the Python client (or via the REST API endpoints using the Clarifai API key). Instead, you need to use the (currently undocumented) REST API part to first login to get the authentication token, and then to access /apps
and /billing_usage
endpoints.
- Login:
POST to https://api.clarifai.com/v2/login
{
"email": "YOUR_EMAIL",
"password": "YOUR_PASSWORD"
}
The session token is in the session_token
response field.
- The
/apps
endpoint:
Use the session token in the header X-Clarifai-Session-Token
, in a GET https://api.clarifai.com/v2/apps
request. The INPUTS and CONCEPTS values are in your app's input_count -> processed
and active_concept_count
fields.
- The
/billing_usage
endpoint:
Send a GET request to https://api.clarifai.com/v2/billing_usage
(it requires X-Clarifai-Session-Token
as well).
from clarifai-python.
Hey @jubins I'm curous what you use case for seeing that information is through the API?
We are currently thinking through new authentication in the API and want to make sure your use case is covered.
from clarifai-python.
Hi @rok-povsic, just a follow-up question on the /billing_usage
endpoint. What are the parameters for start and end dates?
I'm trying to make a request like in below screenshot, where I want to see usage from 2018 onwards
from clarifai-python.
Hi @jubins, I believe that currently the /billing_usage
endpoint takes no input parameters, so it's not possible to get usage from a certain date onward. But let me make sure and I'll follow up.
from clarifai-python.
Hi @jubins, that's correct, the /billing_usage
endpoint takes no parameters and is currently the only available billing usage endpoint.
from clarifai-python.
Hi @rok-povsic, thanks for confirming and all the help on this. I'll close this issue now.
from clarifai-python.
Related Issues (20)
- TypeError: __init__() missing 1 required positional argument: 'descriptor_pool' HOT 4
- pip install fail on Python 3.6.0 HOT 1
- Tests are installed to system site-packages
- Import Clarifai works in Django project, but not in vanilla .py file. HOT 1
- Issue in Explicit wait using selenium with Python
- TypeError: Couldn't build proto file into descriptor pool! HOT 2
- How can I get coordinates of bounding box?
- Getting an error in python grpc client HOT 2
- ModuleNotFoundError: No module named 'clarifai.rest' HOT 1
- I have issue with d 'clarifai.rest' HOT 1
- TQDM version HOT 2
- Handler added to root logger
- Loosen requirement constraints
- Consider switching to `python -m build`
- Message type "clarifai.api.ModelVersion" has no field named "train_stats" HOT 2
- ClarifaiApp constructor error HOT 4
- ApiError.response is None if no internet connection HOT 4
- 2.4.2 Commits & Changelog HOT 1
- multiprocessing bug, requests HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from clarifai-python.