Look, this is not easy stuff. There is a complex interaction of many issues coming together in a single moment which create a problematical situation that is difficult to resolve not just in your instance, but all instances. Not only that, we're getting into pure hypothetical discussion because we don't know the police side of the story. I think it entirely possible there could be a factual predicate for the police to act as they did. And, even if what the FEDERAL agents did was against STATE law, they didn't really act in the outrageous manner many of the cases regarding strip searches do. You weren't on the street in public, they didn't have a member of the opposite sex do a physical search with insertion and any number of other things some stupid or evil cop did. I wouldn't be surprised if they followed their agency procedure in the way they did the search.
You need an attorney with knowledge of all the facts to advise you on your situation. With the story you've told us so far, any civil rights attorney will at least listen to your claim to see if they want to get involved. Get an attorney.
But, saying all that, the police are allowed to detain you for a reasonable investigation if they have a reasonable suspicion you are involved with a crime. If in that reasonable investigation they reasonably believe that evidence of the crime they reasonably suspect you of for reasonable reasons is secreted on your body (Or suitcase, or whatever) they may be said to have "probable cause" to search, um, reasonably.
However, some searches, because of the intrusion, need to have a judge review the reasonableness to see if there is probable cause. Sometimes, specific statutes otherwise empower such searches. But, the cops are not going to do surgery to evacuate a person's stomach to get the joint they believe he swallowed because that wouldn't be---(come on, you know what I'm going to say)--reasonable.
I certainly believe they coerced your consent. But, that is a difficult issue too. If they did find something on you, that may rise to a 4th amendment violation and might be excluded, but how does that translate to damages? The question will be if consent was needed in the first place, and, if so, did the actions of the police make your consent involuntary? I could go on, but they write law review and journal articles on small portions of this area of the law affecting your set of facts. SSRN may have some good ones.