Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

176
Visualizações
Rails. I can't see my plan subscription in Stripe::Customer.retrieve("cus_XYZ") console

I have created my product with price and when I go to consult the clients the subscription field does not appear.

# rails console
Stripe::Customer.retrieve("cus_XYZ")

However, the subscription appears when I run in the console:

Stripe::Subscription.retrieve("sub_1XYZ")

I'd like it to appear when I do a query Stripe::Customer.retrieve, as I need the "subscription" field appears it

If there is any way to retrieve the subscription field in customer I would be very grateful to know.

over 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

As noted in the API reference, the subscriptions are expandable and not included by default.

You can get these, but you need to explicitly request them via expansion:

Stripe::Customer.retrieve({
  id: 'cus_123',
  expand: ['subscriptions'],
})
over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda