Is there a way I can store a Key that will be generated from the backend to the Custom attribute in Dev App?

Not applicable

4497-devappcustomattribute.png

How can I add a dynamic value for the custom attribute for the Developer App. Let's say that the backend has a generated key, so it should be stored in the Custom Attribute value field. and when the backend sends another key, the existing key value should be changed to the new key that was passed by the backend.

Another, Can I use KVM to store the key value pair that will be passed by the backend? and then set the values obtained to the custom attribute?

1 5 316
5 REPLIES 5

How can I add a dynamic value for the custom attribute for the Developer App?

There is a UI for that - you can modify the Developer App and paste in the value, if you like. You are showing this in your screenshot, so I suppose this is not the answer you are looking for. There is also an API for the same modification; in fact, as with everything in the Apigee Edge UI, the UI function is built on the documented Apigee Edge Administrative API.

and when the backend sends another key, the existing key value should be changed to the new key that was passed by the backend.

OK, now it sounds like you want to update the custom attribute at runtime, based on the response that is received in an API call. Is that right?

If so, then that's outside the mainstream use case for Custom Attributes. That mechanism is intended to be set administratively, and rarely updated. By "rarely" I mean, not dynamically with potentially each API call. Sure, you could change it 25 times per day, but that's kinda rare.

The KVM (as you suggested) is ideal for this use case.

Can I use KVM to store the key value pair that will be passed by the backend?

Yes. There is a KVM Operations policy, which allows you to PUT and GET items into the KVM at runtime within the API request or response flow.

and then set the values obtained to the custom attribute?

I don't understand; why would you want to do that? You can GET from the KVM on the subsequent API call, and retrieve the value. You don't need custom attributes for that. If you still think you need custom attributes, maybe you can explain in more detail what you would like to do.

Also, I don't understand why this is a developer portal question. You have it in the developer portal category. Probably there's something about your situation I am misunderstanding.

Let's say the backend passes a private and public key. Then I need to store the public key as a custom attribute of the Developer App. And when the backed passes another public key, the value of the public key in the custom attribute should be changed to the new value passed by the backend. Is this possible?

I understand what you've written here, but... I don't understand why you are prescribing the solution to be . "I store the public key as a custom attribute of the developer app". Why can you not use the cache or KVM to store such artifacts? If the "backend" is the API backend, this is something that happens at runtime, not at provisioning time.

But maybe I am misunderstanding what you mean by "backend". Perhaps you could explain in more than 2 sentences... the actors, the process, the messages flowing back and forth.

The keys that are passed are from the JAVA backend. Java will send the keys to Apigee and Apigee should be able to store the public key as a custom attribute of the developer App. I am not sure if this is logical. So I need your help to verify if this is at least possible to be implemented.

Yes, I think I have not been clear. Sorry about that. Maybe this will clarify things:

1. NO, you cannot update custom attributes of a developer within an API Proxy.

2. It is not logical to try to update custom attributes on Developers or other entities from within an API Proxy. That's not what these attributes are designed for.

3. You shouldn't need to do that; you can use KVM or Cache, it will work better, and these things are designed for your use case.