I'm writing a program which personalizes tokens.My end goal here is to find a way to get the required fields for the token from the CA. Is that possible and if so how?
If by fields you mean certificate fields that are "required" in your configuration you can retrieve certificate and end entity profiles using the WS. Parsing them is a bit tricky, but you can find everything configured in the profiles there.