When attempting to run some CF CLI commands, the response is:
Tanzu CF API version 3.0.0 or higher is required. Your target version is too old
FAILED
An example of this is the new cf user command, introduced in CF CLI v10
TPCF <10.3.0
This is due to a new field, tanzu_version, introduced in 10.3.0
Checking on TPCF 10.3.0, if you run:
curl -sk https://api.<api-endpoint>
{
"links": {
"self": {
"href": "https://api.<api-endpoint>"
},
"cloud_controller_v3": {
"href": "https://api.<api-endpoint>/v3",
"meta": {
"version": "3.203.0",
"tanzu_version": "3.0.5"
}
},
You can see v3 has a "tanzu_version".
If I test the same in 6.0.21:
{
"links": {
"self": {
"href": "https://api.<api-endpoint>"
},
"cloud_controller_v3": {
"href": "https://api.<api-endpoint>/v3",
"meta": {
"version": "3.203.0"
}
},
There is no tanzu version.
Some new commands in the CF CLI, like cf user, explicitly look for this tanzu_version. So if you attempt to run cf user on a TPCF env lower than 10.3.0, you will see the error message.
TPCF will need to be upgraded to 10.3.0 in order for the new commands to work.