Chris Rock at the Academy Awards last month. (Kevin Winter/Getty Images)

Chris Rock made a surprise appearance at L.A.’s Comedy Store two weeks ago, where he riffed about attending President Obama’s 50th-birthday bash at the White House last August. Looks like someone in the club taped Rock’s routine on a cellphone; the video was posted on RealTalkNY this weekend.

“I felt like I died and went to black heaven, I really did,” he told the audience. “It was the most unbelievable experience of my life. . . There were some like, official white people there, like [Treasury Secretary Timothy] Geithner, the vice president, like those kind of white people.”

It’s Rock being Rock but also a breach of the informal code of silence surrounding the event. The party — paid for by the Obamas, according to the White House — was closed to the press and not on the president’s official schedule, although details and the guests list leaked out: an informal barbecue and dancing in the Rose Garden and East Room, chocolate birthday cake and 200 VIP guests like Jay-Z, Tom Hanks, Hill Harper, Charles Barkley, Steve Harvey, Whoopi Goldberg, Emmitt Smith and Gayle King.

Stevie Wonder on Sunday at the Java Jazz Festival in Jakarta. (Supri/Reuters)

In his stand-up routine, Rock was a little more explicit. He said that while watching Wonder and Hancock, he and Jay-Z realized they would never be called to perform at the White House: “The president’s never going to go, ‘Yes, “Big Pimpin’!” How’d you like that? Yes “Big Pimpin’’’ was amazing! Next year Jay’s gonna do “Money, Cash, Hoes.” ’ No, it’s never going to happen. Let’s just be glad we’re invited.”

As the party went on, he said, the music got “blacker and blacker.” The DJ played Beyonce’s “Crazy in Love” and Malia and Sasha started dancing. “They came from outta nowhere and . . . started doing the Dougie.”

That’s when Rock said it hit him: “Think about this [expletive] moment: A bunch of black people doing the [expletive] Dougie in the house that slaves made.”

The White House did not respond to requests for comment.

(Warning: Rock’s monologue may not be suitable for sensitive ears. But you knew that.) (UPDATE, 3/7: Surprise, surprise — it’s been pulled , “due to a copyright claim from Chris Rock Enterprises Inc.”)

Video: Chris Rock at the Comedy Store.

Read related: Chris Rock isn’t the only comedian to get material out of a presidential brush with greatness. David Cross claims he did coke in front of president — and room full of journalists, 2/23/12

Read earlier: Obama’s Rose Garden 50th birthday bash, 8/4/11