Answers.Body: <p>Like this:</p>
  
  <pre><code>{% if cart.paymentMethod.class == 'Stripe' %}
      {{ cart.paymentMethod.settings.publishableKey }}
  {% endif %}
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2018-01-24T16:03:32.603Z
Answers.Text: Thanks. Works like a charm. Is this documented somewhere?
Answers.UserDisplayName: outline4
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2018-01-25T08:58:33.100Z
Answers.Text: I'm not sure. I just checked the payment method model + the database.
Answers.UserDisplayName: Fred Carlsen
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2018-01-24T11:50:36.937Z
Answers.LastActivityDate: 2018-01-24T11:50:36.937Z
Answers.UserDisplayName: Fred Carlsen
Body: <p>I would like to know how I can output Craft Commerces Stripes Publishable Key, which I define under Payment Methods, in a template? </p>
  
  <p>The value I set is settings[publishableKey].</p>
  
  <p>Thanks<br>
  Stefan </p>
  
Tags: <plugin-craftcommerce>
Title: How I can output Craft Commerces Stripes Publishable Key in a template
ThreadText: # How I can output Craft Commerces Stripes Publishable Key in a template
  
  (Asked by: username_0 on 2018-01-24)
  
  I would like to know how I can output Craft Commerces Stripes Publishable Key, which I define under Payment Methods, in a template?
  
  The value I set is settings[publishableKey].
  
  Thanks  
  Stefan
  
  **Tags:** plugin-craftcommerce
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2018-01-24. Score: 1 | Accepted answer
  
  Like this:
  
  ```
  {% if cart.paymentMethod.class == 'Stripe' %}
      {{ cart.paymentMethod.settings.publishableKey }}
  {% endif %}
  
  ```
  
  > **Comments:**
  > **username_0**: Thanks. Works like a charm. Is this documented somewhere?  
  > **username_1**: I'm not sure. I just checked the payment method model + the database.  
  
  ---
  
  