If the car was originally a Trans Am, it would have come with a GM "positrac" differential, which is an Eaton design and it had 10 bolts holding the ring gear to the carrier ("aka "10 bolt") and an 8.50" ring gear diameter. All Firebird/Camaro rear ends were actually built by Chevrolet so it get's confusing looking for parts sometimes because it's a "Chevrolet" rear end even though it's in a Pontiac car.
Sounds like you have mismatched axles and somebody rebuilt the rear end with Richmond gears and an aftermarket Auburn limited slip differential. I'm no expert but I think Auburn positracs are a "cone" type and not rebuildable... which some people count as a mark against them. I have no opinion. Richmond gears are like anything... some say they are fine... some say not. In my experience the set-up is more important than the gear brand.
Assuming your car has the correct housing then the 30-1/16" inch axle should be right and the longer one is incorrect. I didn't quite follow how you were measuring the axles. I got the pic below from the Dutchman Axles website, and it shows how to measure.
As far as figuring out the gear ratio, the best way is to count the gear teeth since it's opened up anyway.
Ratio = number of teeth on Ring Gear divided by number of teeth on pinion gear.
Count the teeth on both gears and divide with a calculator. A 4.10 or 4.11 may be steeper than needed. Even a mildly built Pontiac 400 generally has plenty of low end torque and so a ratio more like 3.50 or so is more commonly picked. You can fill books with that discussion, so I'll leave it at that.
If I had 400 HP on tap, I would want aftermarket axles. Axles do beak sometimes, and a C-clip axle will come out of the housing when that happens. I used Dutchman SR axles on my car.
Lastly - Factory axles had 28 splines. Some aftermarket differentials are available with 31 splines. You should double-check what you have before ordering anything.
...